Pažymiai

Taškai: 0

Compile: FAIL

pazymiai.cpp: In function ‘int main()’: pazymiai.cpp:21:42: error: no matching function for call to ‘std::vector<std::__cxx11::basic_string<char> >::insert(std::__cxx11::string&)’ marsieciai[pazymys].insert(vardas); ^ In file included from /usr/include/c++/5/vector:69:0, from /usr/include/c++/5/bits/random.h:34, from /usr/include/c++/5/random:49, from /usr/include/c++/5/bits/stl_algo.h:66, from /usr/include/c++/5/algorithm:62, from /usr/include/x86_64-linux-gnu/c++/5/bits/stdc++.h:64, from pazymiai.cpp:1: /usr/include/c++/5/bits/vector.tcc:107:5: note: candidate: std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::insert(std::vector<_Tp, _Alloc>::const_iterator, const value_type&) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; std::vector<_Tp, _Alloc>::iterator = __gnu_cxx::__normal_iterator<std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename std::_Vector_base<_Tp, _Alloc>::pointer = std::__cxx11::basic_string<char>*; std::vector<_Tp, _Alloc>::const_iterator = __gnu_cxx::__normal_iterator<const std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename __gnu_cxx::__alloc_traits<typename std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type>::const_pointer = const std::__cxx11::basic_string<char>*; std::vector<_Tp, _Alloc>::value_type = std::__cxx11::basic_string<char>] vector<_Tp, _Alloc>:: ^ /usr/include/c++/5/bits/vector.tcc:107:5: note: candidate expects 2 arguments, 1 provided In file included from /usr/include/c++/5/vector:64:0, from /usr/include/c++/5/bits/random.h:34, from /usr/include/c++/5/random:49, from /usr/include/c++/5/bits/stl_algo.h:66, from /usr/include/c++/5/algorithm:62, from /usr/include/x86_64-linux-gnu/c++/5/bits/stdc++.h:64, from pazymiai.cpp:1: /usr/include/c++/5/bits/stl_vector.h:1014:7: note: candidate: std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::insert(std::vector<_Tp, _Alloc>::const_iterator, std::vector<_Tp, _Alloc>::value_type&&) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; std::vector<_Tp, _Alloc>::iterator = __gnu_cxx::__normal_iterator<std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename std::_Vector_base<_Tp, _Alloc>::pointer = std::__cxx11::basic_string<char>*; std::vector<_Tp, _Alloc>::const_iterator = __gnu_cxx::__normal_iterator<const std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename __gnu_cxx::__alloc_traits<typename std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type>::const_pointer = const std::__cxx11::basic_string<char>*; std::vector<_Tp, _Alloc>::value_type = std::__cxx11::basic_string<char>] insert(const_iterator __position, value_type&& __x) ^ /usr/include/c++/5/bits/stl_vector.h:1014:7: note: candidate expects 2 arguments, 1 provided /usr/include/c++/5/bits/stl_vector.h:1031:7: note: candidate: std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::insert(std::vector<_Tp, _Alloc>::const_iterator, std::initializer_list<_Tp>) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; std::vector<_Tp, _Alloc>::iterator = __gnu_cxx::__normal_iterator<std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename std::_Vector_base<_Tp, _Alloc>::pointer = std::__cxx11::basic_string<char>*; std::vector<_Tp, _Alloc>::const_iterator = __gnu_cxx::__normal_iterator<const std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename __gnu_cxx::__alloc_traits<typename std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type>::const_pointer = const std::__cxx11::basic_string<char>*] insert(const_iterator __position, initializer_list<value_type> __l) ^ /usr/include/c++/5/bits/stl_vector.h:1031:7: note: candidate expects 2 arguments, 1 provided /usr/include/c++/5/bits/stl_vector.h:1051:7: note: candidate: std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::insert(std::vector<_Tp, _Alloc>::const_iterator, std::vector<_Tp, _Alloc>::size_type, const value_type&) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; std::vector<_Tp, _Alloc>::iterator = __gnu_cxx::__normal_iterator<std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename std::_Vector_base<_Tp, _Alloc>::pointer = std::__cxx11::basic_string<char>*; std::vector<_Tp, _Alloc>::const_iterator = __gnu_cxx::__normal_iterator<const std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >; typename __gnu_cxx::__alloc_traits<typename std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type>::const_pointer = const std::__cxx11::basic_string<char>*; std::vector<_Tp, _Alloc>::size_type = long unsigned int; std::vector<_Tp, _Alloc>::value_type = std::__cxx11::basic_string<char>] insert(const_iterator __position, size_type __n, const value_type& __x) ^ /usr/include/c++/5/bits/stl_vector.h:1051:7: note: candidate expects 3 arguments, 1 provided /usr/include/c++/5/bits/stl_vector.h:1095:9: note: candidate: template<class _InputIterator, class> std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::insert(std::vector<_Tp, _Alloc>::const_iterator, _InputIterator, _InputIterator) [with _InputIterator = _InputIterator; <template-parameter-2-2> = <template-parameter-1-2>; _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >] insert(const_iterator __position, _InputIterator __first, ^ /usr/include/c++/5/bits/stl_vector.h:1095:9: note: template argument deduction/substitution failed: pazymiai.cpp:21:42: note: cannot convert ‘vardas’ (type ‘std::__cxx11::string {aka std::__cxx11::basic_string<char>}’) to type ‘std::vector<std::__cxx11::basic_string<char> >::const_iterator {aka __gnu_cxx::__normal_iterator<const std::__cxx11::basic_string<char>*, std::vector<std::__cxx11::basic_string<char> > >}’ marsieciai[pazymys].insert(vardas); ^

nr.resulttimemessage