Browse Source

Funktion sucheXWert

main
Jannis 2 years ago
parent
commit
509703392f
  1. 15
      src/Spiellogik.c

15
src/Spiellogik.c

@ -10,6 +10,21 @@
int speed = 0; int speed = 0;
int sucheXWert(int realU[N][N]){
int groesste = 0;
int ii;
for(int i = 0; i < N ; i++){
for(int j = 0; j < N; j++){
if (realU[i][j] > groesste && realU[i][j] != (N * N) + 1){
groesste = realU[i][j];
ii = i;
}
}
return i;
}
}
int win(int realU[N][N]){ int win(int realU[N][N]){
int groesste = 0; int groesste = 0;
for(int i = 0; i < N; i++){ for(int i = 0; i < N; i++){

Loading…
Cancel
Save