F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_38903321_15784.cpp: In function 'void solve(int)':
0_0_38903321_15784.cpp:11:49: error: no matching function for call to 'std::vector<std::vector<char> >::vector(int, std::vector<int>)'
   11 |     vector<vector<char>> a(n+1, vector<int>(n+1));
      |                                                 ^
In file included from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/vector:66,
                 from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/functional:64,
                 from .\stdc++.h:53:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:702:9: note: candidate: 'template<class _InputIterator, class> constexpr std::vector<_Tp, _Alloc>::vector(_InputIterator, _InputIterator, const allocator_type&) [with <template-parameter-2-2> = _InputIterator; _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >]'
  702 |         vector(_InputIterator __first, _InputIterator __last,
      |         ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:702:9: note:   template argument deduction/substitution failed:
0_0_38903321_15784.cpp:11:49: note:   deduced conflicting types for parameter '_InputIterator' ('int' and 'std::vector<int>')
   11 |     vector<vector<char>> a(n+1, vector<int>(n+1));
      |                                                 ^
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:673:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(std::initializer_list<_Tp>, const allocator_type&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; allocator_type = std::allocator<std::vector<char> >]'
  673 |       vector(initializer_list<value_type> __l,
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:673:43: note:   no known conversion for argument 1 from 'int' to 'std::initializer_list<std::vector<char> >'
  673 |       vector(initializer_list<value_type> __l,
      |              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:654:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(std::vector<_Tp, _Alloc>&&, std::__type_identity_t<_Alloc>&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; std::__type_identity_t<_Alloc> = std::allocator<std::vector<char> >]'
  654 |       vector(vector&& __rv, const __type_identity_t<allocator_type>& __m)
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:654:23: note:   no known conversion for argument 1 from 'int' to 'std::vector<std::vector<char> >&&'
  654 |       vector(vector&& __rv, const __type_identity_t<allocator_type>& __m)
      |              ~~~~~~~~~^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:635:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(std::vector<_Tp, _Alloc>&&, const allocator_type&, std::false_type) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; allocator_type = std::allocator<std::vector<char> >; std::false_type = std::integral_constant<bool, false>]'
  635 |       vector(vector&& __rv, const allocator_type& __m, false_type)
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:635:7: note:   candidate expects 3 arguments, 2 provided
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:630:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(std::vector<_Tp, _Alloc>&&, const allocator_type&, std::true_type) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; allocator_type = std::allocator<std::vector<char> >; std::true_type = std::integral_constant<bool, true>]'
  630 |       vector(vector&& __rv, const allocator_type& __m, true_type) noexcept
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:630:7: note:   candidate expects 3 arguments, 2 provided
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:619:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(const std::vector<_Tp, _Alloc>&, std::__type_identity_t<_Alloc>&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; std::__type_identity_t<_Alloc> = std::allocator<std::vector<char> >]'
  619 |       vector(const vector& __x, const __type_identity_t<allocator_type>& __a)
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:619:28: note:   no known conversion for argument 1 from 'int' to 'const std::vector<std::vector<char> >&'
  619 |       vector(const vector& __x, const __type_identity_t<allocator_type>& __a)
      |              ~~~~~~~~~~~~~~^~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:615:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(std::vector<_Tp, _Alloc>&&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >]'
  615 |       vector(vector&&) noexcept = default;
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:615:7: note:   candidate expects 1 argument, 2 provided
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:596:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(const std::vector<_Tp, _Alloc>&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >]'
  596 |       vector(const vector& __x)
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:596:7: note:   candidate expects 1 argument, 2 provided
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:564:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(size_type, const value_type&, const allocator_type&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; size_type = long long unsigned int; value_type = std::vector<char>; allocator_type = std::allocator<std::vector<char> >]'
  564 |       vector(size_type __n, const value_type& __value,
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:564:47: note:   no known conversion for argument 2 from 'std::vector<int>' to 'const std::vector<std::vector<char> >::value_type&' {aka 'const std::vector<char>&'}
  564 |       vector(size_type __n, const value_type& __value,
      |                             ~~~~~~~~~~~~~~~~~~^~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:551:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(size_type, const allocator_type&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; size_type = long long unsigned int; allocator_type = std::allocator<std::vector<char> >]'
  551 |       vector(size_type __n, const allocator_type& __a = allocator_type())
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:551:51: note:   no known conversion for argument 2 from 'std::vector<int>' to 'const std::vector<std::vector<char> >::allocator_type&' {aka 'const std::allocator<std::vector<char> >&'}
  551 |       vector(size_type __n, const allocator_type& __a = allocator_type())
      |                             ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:537:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector(const allocator_type&) [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >; allocator_type = std::allocator<std::vector<char> >]'
  537 |       vector(const allocator_type& __a) _GLIBCXX_NOEXCEPT
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:537:7: note:   candidate expects 1 argument, 2 provided
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:526:7: note: candidate: 'constexpr std::vector<_Tp, _Alloc>::vector() [with _Tp = std::vector<char>; _Alloc = std::allocator<std::vector<char> >]'
  526 |       vector() = default;
      |       ^~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/stl_vector.h:526:7: note:   candidate expects 0 arguments, 2 provided


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-26 12:07:38, Gzip enabled