bridge.cpp: In function 'int main()':
bridge.cpp:63:25: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11
v.push_back({x, y});
^
bridge.cpp:63:31: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11
v.push_back({x, y});
^
bridge.cpp:69:5: warning: lambda expressions only available with -std=c++11 or -std=gnu++11
});
^
bridge.cpp:69:6: error: no matching function for call to 'sort(std::vector<std::pair<int, int> >::iterator, std::vector<std::pair<int, int> >::iterator, main()::<lambda(ii, ii)>)'
});
^
In file included from /usr/include/c++/5/algorithm:62:0,
from bridge.cpp:2:
/usr/include/c++/5/bits/stl_algo.h:4689:5: note: candidate: template<class _RAIter> void std::sort(_RAIter, _RAIter)
sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
^
/usr/include/c++/5/bits/stl_algo.h:4689:5: note: template argument deduction/substitution failed:
bridge.cpp:69:6: note: candidate expects 2 arguments, 3 provided
});
^
In file included from /usr/include/c++/5/algorithm:62:0,
from bridge.cpp:2:
/usr/include/c++/5/bits/stl_algo.h:4718:5: note: candidate: template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare)
sort(_RandomAccessIterator __first, _RandomAccessIterator __last,
^
/usr/include/c++/5/bits/stl_algo.h:4718:5: note: template argument deduction/substitution failed:
bridge.cpp: In substitution of 'template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare) [with _RAIter = __gnu_cxx::__normal_iterator<std::pair<int, int>*, std::vector<std::pair<int, int> > >; _Compare = main()::<lambda(ii, ii)>]':
bridge.cpp:69:6: required from here
bridge.cpp:69:6: error: template argument for 'template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare)' uses local type 'main()::<lambda(ii, ii)>'
});
^
bridge.cpp:69:6: error: trying to instantiate 'template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare)'
bridge.cpp:47:27: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d %d", &k, &n);
^
bridge.cpp:56:48: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf(" %c %d %c %d", &c1, &x, &c2, &y);
^