Borderou de evaluare (job #1628715)
Utilizator | Data | 4 martie 2016 10:15:40 | |
---|---|---|---|
Problema | Cezar | Status | done |
Runda | Arhiva de probleme | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘void initializare()’:
user.cpp:60:32: error: no matching function for call to ‘std::vector<std::vector<short unsigned int> >::assign(int, std::vector<int>)’
G.assign(N+2, vector<int>());
^
user.cpp:60:32: 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<short unsigned int>; _Alloc = std::allocator<std::vector<short unsigned int> >; std::vector<_Tp, _Alloc>::size_type = unsigned int; std::vector<_Tp, _Alloc>::value_type = std::vector<short unsigned 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 ‘std::vector<int>’ to ‘const value_type& {aka const std::vector<short unsigned 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<short unsigned int>; _Alloc = std::allocator<std::vector<short unsigned int> >]
assign(_InputIterator __first, _InputIterator __last)
^
/usr/include/c++/4.8/bits/stl_vector.h:498:9: note: template argument deduction/substitution failed:
user.cpp:60:32: note: deduced conflicting types for parameter ‘_InputIterator’ (‘int’ and ‘std::vector<int>’)
G.assign(N+2, vector<int>());
^
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:524:7: note: void std::vector<_Tp, _Alloc>::assign(std::initializer_list<_Tp>) [with _Tp = std::vector<short unsigned int>; _Alloc = std::allocator<std::vector<short unsigned 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:64:29: warning: format ‘%d’ expects argument of type ‘int*’, but argument 2 has type ‘short unsigned int*’ [-Wformat=]
scanf("%d%d", &x, &y);
^
user.cpp:64:29: warning: format ‘%d’ expects argument of type ‘int*’, but argument 3 has type ‘short unsigned int*’ [-Wformat=]
user.cpp:57:37: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("cezar.in", "rt", stdin);
^
user.cpp:58:39: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("cezar.out", "wt", stdout);
^
user.cpp:59:26: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d", &N, &K);
^
user.cpp:64:30: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d", &x, &y);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !