|
|
вернуться в форумbefore output I check arrays: for(i = 0; i < n; i++) for(j = 1; j < m; j++) if( a[i][j-1] == a[i][j] && b[i][j-1] == b[i][j] ) while(1);
for(i = 1; i < n; i++) for(j = 0; j < m; j++) if( a[i-1][j] == a[i][j] && b[i-1][j] == b[i][j] ) while(1); and I have wa4, not TL Did you number the bricks correctly? I numbered bricks by squares: xx yy
or xy xy Maybe it wrong? Use int instead of char. There can be numbers up to 5000 in the answer. |
|
|