2025-06-14 23:26:42 +02:00

47 lines
943 B
C

#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include "cell/cell.h"
#include "communication/communication.h"
#include "leelib/leelib.h"
#include "robot/robot.h"
#include "robot/challenges/challenges.h"
extern int unexpanded_matrix[MAZE_SIZE][MAZE_SIZE];
extern int visited[MAZE_SIZE][MAZE_SIZE];
extern const cell neighbours[4];
void addBlock(robot r, cell move, direction dir, cell targetCell, stack *s);
int main(int argc, char *argv[]) {
/* read the starting and end station.*/
if (argc < 2) {
printf("NOT ENOUGH ARGUMENTS \n");
printf("USAGE: ./maze <CHALLENGE NR or 0 for simple remote> \n");
return -1;
}
switch (strtol(argv[1],NULL, 10)) {
case 0:
simple_control();
break;
case 2:
challenge_2();
break;
case 3:
challenge_3((cell){10,3});
break;
case 4:
challenge_4((cell){10,3});
break;
default:
printf("DOESNT WORK YET \n");
break;
}
return 0;
}