Borderou de evaluare (job #1531362)
Utilizator | Data | 21 noiembrie 2015 13:42:25 | |
---|---|---|---|
Problema | Por Costel și Trenul | Status | done |
Runda | FMI No Stress 6 | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘int main()’:
user.cpp:17:17: error: no matching function for call to ‘std::vector<std::vector<int> >::assign(int&, int)’
sol.assign (m,0);
^
user.cpp:17:17: note: candidates are:
In file included from /usr/include/c++/4.8/vector:64:0,
from user.cpp:3:
/usr/include/c++/4.8/bits/stl_vector.h:479:7: note: void std::vector<_Tp, _Alloc>::assign(std::vector<_Tp, _Alloc>::size_type, const value_type&) [with _Tp = std::vector<int>; _Alloc = std::allocator<std::vector<int> >; std::vector<_Tp, _Alloc>::size_type = unsigned int; std::vector<_Tp, _Alloc>::value_type = std::vector<int>]
assign(size_type __n, const value_type& __val)
^
/usr/include/c++/4.8/bits/stl_vector.h:479:7: note: no known conversion for argument 2 from ‘int’ to ‘const value_type& {aka const std::vector<int>&}’
/usr/include/c++/4.8/bits/stl_vector.h:498:9: note: template<class _InputIterator, class> void std::vector<_Tp, _Alloc>::assign(_InputIterator, _InputIterator) [with _InputIterator = _InputIterator; <template-parameter-2-2> = <template-parameter-1-2>; _Tp = std::vector<int>; _Alloc = std::allocator<std::vector<int> >]
assign(_InputIterator __first, _InputIterator __last)
^
/usr/include/c++/4.8/bits/stl_vector.h:498:9: note: template argument deduction/substitution failed:
/usr/include/c++/4.8/bits/stl_vector.h:524:7: note: void std::vector<_Tp, _Alloc>::assign(std::initializer_list<_Tp>) [with _Tp = std::vector<int>; _Alloc = std::allocator<std::vector<int> >]
assign(initializer_list<value_type> __l)
^
/usr/include/c++/4.8/bits/stl_vector.h:524:7: note: candidate expects 1 argument, 2 provided
user.cpp:82:31: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < pos2.size(); i++) {
^
user.cpp:104:30: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < sol.size(); i++) {
^
user.cpp:106:33: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int j = 0; j < v.size() - 1; j++)
^
user.cpp:14:32: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("trenul.in","r",stdin);
^
user.cpp:15:34: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("trenul.out","w",stdout);
^
user.cpp:22:17: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&c);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !