Se dă un șir de matrice pătratice asupra căruia se pot face două tipuri de operații: actualizare a unui element (se înlocuiește matricea de pe acea poziție cu alta) și interogarea unui interval de indici (determinarea produsului matricelor memorate între cei doi indici, inclusiv).
Problema | Actualizare Element, Produs Interval, Matrice | Operații I/O |
aepim.in /aepim.out
|
---|---|---|---|
Limita timp | 0.5 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #46560658 | Utilizator | |
Fișier | actualizare_element,_produs_interval,_matrice.cpp | Dimensiune | 2.86 KB |
Data încărcării | 16 Noiembrie 2023, 23:47 | Scor / rezultat | 90 puncte |
actualizare_element,_produs_interval,_matrice.cpp: In function 'std::vector<short int> produs(std::vector<short int>, std::vector<short int>)': actualizare_element,_produs_interval,_matrice.cpp:14:55: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:55: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:99: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:99: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:141: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:141: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:183: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:183: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:227: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:227: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:272: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:272: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:317: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:317: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:362: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:362: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(4u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:14:407: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 *x[0]*y[0]+1*x[1]*y[3]+1*x[2]*y[6])%mod,(1 *x[0]*y[1]+1*x[1]*y[4]+1 *x[2]*y[7])%mod,(1*x[0]*y[2]+1*x[1]*y[5]+1*x[2]*y[8])%mod,(1*x[3]*y[0]+1*x[4]*y[3]+1*x[5]*y[6])%mod,(1 *x[3]*y[1]+1*x[4]*y[4]+1 *x[5]*y[7])%mod,(1 *x[3]*y[2]+1 *x[4]*y[5]+1 *x[5]*y[8])%mod,(1 *x[6]*y[0]+1 *x[7]*y[3]+1 *x[8]*y[6])%mod,(1 *x[6]*y[1]+1 *x[7]*y[4]+1 *x[8]*y[7])%mod,(1 *x[6]*y[2]+1 *x[7]*y[5]+1 *x[8]*y[8])%mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:14:407: warning: narrowing conversion of '((((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(6u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(7u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(5u)))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(8u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:15:49: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 * x[0] * y[0] + 1 * x[1] * y[2]) % mod,(1 * x[0] * y[1] + 1 *x[1] * y[3]) % mod,(1 *x[2] * y[0] + 1 *x[3] * y[2]) % mod,(1 *x[2] * y[1] + 1*x[3] * y[3]) % mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:15:49: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:15:90: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 * x[0] * y[0] + 1 * x[1] * y[2]) % mod,(1 * x[0] * y[1] + 1 *x[1] * y[3]) % mod,(1 *x[2] * y[0] + 1 *x[3] * y[2]) % mod,(1 *x[2] * y[1] + 1*x[3] * y[3]) % mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:15:90: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:15:130: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 * x[0] * y[0] + 1 * x[1] * y[2]) % mod,(1 * x[0] * y[1] + 1 *x[1] * y[3]) % mod,(1 *x[2] * y[0] + 1 *x[3] * y[2]) % mod,(1 *x[2] * y[1] + 1*x[3] * y[3]) % mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:15:130: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(0u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp:15:169: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] return {(1 * x[0] * y[0] + 1 * x[1] * y[2]) % mod,(1 * x[0] * y[1] + 1 *x[1] * y[3]) % mod,(1 *x[2] * y[0] + 1 *x[3] * y[2]) % mod,(1 *x[2] * y[1] + 1*x[3] * y[3]) % mod}; ^ actualizare_element,_produs_interval,_matrice.cpp:15:169: warning: narrowing conversion of '(((((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(2u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(1u))) + (((int)x.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)) * ((int)y.std::vector<_Tp, _Alloc>::operator[]<short int, std::allocator<short int> >(3u)))) % 9901)' from 'int' to 'short int' inside { } [-Wnarrowing] actualizare_element,_produs_interval,_matrice.cpp: In function 'std::vector<short int> interogare(int, int, int)': actualizare_element,_produs_interval,_matrice.cpp:38:9: warning: unused variable 'fs' [-Wunused-variable] int fs = 2 * p + 1, fd = 2*p+2, m = ((st+dr)>>1), ok = 0; ^ actualizare_element,_produs_interval,_matrice.cpp:38:25: warning: unused variable 'fd' [-Wunused-variable] int fs = 2 * p + 1, fd = 2*p+2, m = ((st+dr)>>1), ok = 0; ^
Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
---|---|---|---|---|---|---|
1 | 0.024 secunde | OK. | 10 | 10 | ||
2 | 0.008 secunde | OK. | 10 | 10 | ||
3 | 0.008 secunde | OK. | 10 | 10 | ||
4 | 0.008 secunde | OK. | 10 | 10 | ||
5 | 0.008 secunde | OK. | 10 | 10 | ||
6 | 0.044 secunde | OK. | 10 | 10 | ||
7 | 0.192 secunde | OK. | 10 | 10 | ||
8 | 0.356 secunde | OK. | 10 | 10 | ||
9 | 0.408 secunde | OK. | 10 | 10 | ||
10 | Depășit | Limita de timp depășită | 10 | 0 | ||
Punctaj total | 90 |
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Actualizare Element, Produs Interval, Matrice face parte din prima categorie. Soluția propusă de tine va fi evaluată astfel:
Suma punctajelor acordate pe testele utilizate pentru verificare este 100. Astfel, soluția ta poate obține cel mult 100 de puncte, caz în care se poate considera corectă.