semafor.cpp: In function 'int main()':
semafor.cpp:127:42: error: incompatible types in assignment of 'std::vector<std::vector<long long int> >' to 'Mat [1510]' {aka 'std::vector<std::vector<long long int> > [1510]'}
127 | P=vector<vector<ll>>(10, vector<ll>(10));
| ^
semafor.cpp:134:27: error: no match for 'operator=' (operand types are '__gnu_cxx::__alloc_traits<std::allocator<std::vector<long long int> >, std::vector<long long int> >::value_type' {aka 'std::vector<long long int>'} and '__gnu_cxx::__alloc_traits<std::allocator<long long int>, long long int>::value_type' {aka 'long long int'})
134 | P[i][j]=B[MM[i]][MM[j]];
| ^
In file included from /usr/include/c++/9/vector:72,
from /usr/include/c++/9/queue:61,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:86,
from semafor.cpp:1:
/usr/include/c++/9/bits/vector.tcc:198:5: note: candidate: 'std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(const std::vector<_Tp, _Alloc>&) [with _Tp = long long int; _Alloc = std::allocator<long long int>]'
198 | vector<_Tp, _Alloc>::
| ^~~~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/vector.tcc:199:42: note: no known conversion for argument 1 from '__gnu_cxx::__alloc_traits<std::allocator<long long int>, long long int>::value_type' {aka 'long long int'} to 'const std::vector<long long int>&'
199 | operator=(const vector<_Tp, _Alloc>& __x)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
In file included from /usr/include/c++/9/vector:67,
from /usr/include/c++/9/queue:61,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:86,
from semafor.cpp:1:
/usr/include/c++/9/bits/stl_vector.h:706:7: note: candidate: 'std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::vector<_Tp, _Alloc>&&) [with _Tp = long long int; _Alloc = std::allocator<long long int>]'
706 | operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move())
| ^~~~~~~~
/usr/include/c++/9/bits/stl_vector.h:706:26: note: no known conversion for argument 1 from '__gnu_cxx::__alloc_traits<std::allocator<long long int>, long long int>::value_type' {aka 'long long int'} to 'std::vector<long long int>&&'
706 | operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move())
| ~~~~~~~~~^~~
/usr/include/c++/9/bits/stl_vector.h:727:7: note: candidate: 'std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::initializer_list<_Tp>) [with _Tp = long long int; _Alloc = std::allocator<long long int>]'
727 | operator=(initializer_list<value_type> __l)
| ^~~~~~~~
/usr/include/c++/9/bits/stl_vector.h:727:46: note: no known conversion for argument 1 from '__gnu_cxx::__alloc_traits<std::allocator<long long int>, long long int>::value_type' {aka 'long long int'} to 'std::initializer_list<long long int>'
727 | operator=(initializer_list<value_type> __l)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
semafor.cpp:140:11: error: could not convert '(Mat*)(& P)' from 'Mat*' {aka 'std::vector<std::vector<long long int> >*'} to 'Mat' {aka 'std::vector<std::vector<long long int> >'}
140 | R=mypow(P, N/K)+Q;
| ^
| |
| Mat* {aka std::vector<std::vector<long long int> >*}
semafor.cpp:60:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
60 | scanf("%d%lld%lld%d", &M, &N, &K, &X);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~