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_36549769_11495.cpp: In function 'void solve()':
0_0_36549769_11495.cpp:44:36: error: no matching function for call to 'std::vector<std::pair<int, int> >::emplace(int&, int&)'
     f[1][1].emplace(a[1][1],b[1][1]);
                                    ^
0_0_36549769_11495.cpp:44:36: note: candidate is:
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/vector:64:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/random.h:34,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/random:49,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algo.h:66,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:62,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/x86_64-w64-mingw32/bits/stdc++.h:64,
                 from 0_0_36549769_11495.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_vector.h:970:9: note: template<class ... _Args> std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::emplace(std::vector<_Tp, _Alloc>::const_iterator, _Args&& ...) [with _Args = {_Args ...}; _Tp = std::pair<int, int>; _Alloc = std::allocator<std::pair<int, int> >]
         emplace(const_iterator __position, _Args&&... __args);
         ^
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_vector.h:970:9: note:   template argument deduction/substitution failed:
0_0_36549769_11495.cpp:44:27: note:   cannot convert 'a[1][1]' (type 'int') to type 'std::vector<std::pair<int, int> >::const_iterator {aka __gnu_cxx::__normal_iterator<const std::pair<int, int>*, std::vector<std::pair<int, int> > >}'
     f[1][1].emplace(a[1][1],b[1][1]);
                           ^
0_0_36549769_11495.cpp:51:82: error: no matching function for call to 'std::vector<std::pair<int, int> >::emplace(int, int)'
                     f[i][j].emplace(f[i][j-1][k].x+a[i][j],f[i][j-1][k].y+b[i][j]);
                                                                                  ^
0_0_36549769_11495.cpp:51:82: note: candidate is:
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/vector:64:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/random.h:34,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/random:49,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algo.h:66,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:62,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/x86_64-w64-mingw32/bits/stdc++.h:64,
                 from 0_0_36549769_11495.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_vector.h:970:9: note: template<class ... _Args> std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::emplace(std::vector<_Tp, _Alloc>::const_iterator, _Args&& ...) [with _Args = {_Args ...}; _Tp = std::pair<int, int>; _Alloc = std::allocator<std::pair<int, int> >]
         emplace(const_iterator __position, _Args&&... __args);
         ^
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_vector.h:970:9: note:   template argument deduction/substitution failed:
0_0_36549769_11495.cpp:51:51: note:   cannot convert '(f[i][(j + -1)].std::vector<_Tp, _Alloc>::operator[]<std::pair<int, int>, std::allocator<std::pair<int, int> > >(((std::vector<std::pair<int, int> >::size_type)k)).std::pair<int, int>::first + a[i][j])' (type 'int') to type 'std::vector<std::pair<int, int> >::const_iterator {aka __gnu_cxx::__normal_iterator<const std::pair<int, int>*, std::vector<std::pair<int, int> > >}'
                     f[i][j].emplace(f[i][j-1][k].x+a[i][j],f[i][j-1][k].y+b[i][j]);
                                                   ^
0_0_36549769_11495.cpp:54:82: error: no matching function for call to 'std::vector<std::pair<int, int> >::emplace(int, int)'
                     f[i][j].emplace(f[i-1][j][k].x+a[i][j],f[i-1][j][k].y+b[i][j]);
                                                                                  ^
0_0_36549769_11495.cpp:54:82: note: candidate is:
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/vector:64:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/random.h:34,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/random:49,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algo.h:66,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:62,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/x86_64-w64-mingw32/bits/stdc++.h:64,
                 from 0_0_36549769_11495.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_vector.h:970:9: note: template<class ... _Args> std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::emplace(std::vector<_Tp, _Alloc>::const_iterator, _Args&& ...) [with _Args = {_Args ...}; _Tp = std::pair<int, int>; _Alloc = std::allocator<std::pair<int, int> >]
         emplace(const_iterator __position, _Args&&... __args);
         ^
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_vector.h:970:9: note:   template argument deduction/substitution failed:
0_0_36549769_11495.cpp:54:51: note:   cannot convert '(f[(i + -1)][j].std::vector<_Tp, _Alloc>::operator[]<std::pair<int, int>, std::allocator<std::pair<int, int> > >(((std::vector<std::pair<int, int> >::size_type)k)).std::pair<int, int>::first + a[i][j])' (type 'int') to type 'std::vector<std::pair<int, int> >::const_iterator {aka __gnu_cxx::__normal_iterator<const std::pair<int, int>*, std::vector<std::pair<int, int> > >}'
                     f[i][j].emplace(f[i-1][j][k].x+a[i][j],f[i-1][j][k].y+b[i][j]);
                                                   ^


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-12-01 14:09:02, Gzip enabled