Compare commits

..

6 Commits

Author SHA1 Message Date
Thilo
4b81d627f5 all bugs fixed 2025-12-16 11:52:11 +01:00
Thilo
326ad66959 Merge branch 'main' of https://git.efi.th-nuernberg.de/gitea/hoockth99140/Doble-Spiel 2025-12-16 11:51:45 +01:00
Thilo
5941913b6c Merge branch 'main' of https://git.efi.th-nuernberg.de/gitea/hoockth99140/Doble-Spiel 2025-12-16 11:47:40 +01:00
Thilo
b8f80512ba all bugs fixed 2025-12-16 11:46:55 +01:00
Thilo
e9fa5b72a5 all bugs fixed 2025-12-16 11:46:12 +01:00
Thilo
ce3de3b8f8 bug fixes! 2025-12-16 09:16:32 +01:00
7 changed files with 11 additions and 3 deletions

Binary file not shown.

View File

@ -1,2 +1,3 @@
player1;4980
player_name;4980
player1;3999

BIN
main.o

Binary file not shown.

View File

@ -41,18 +41,25 @@ stack_test_objects = $(stack_test_sources:.c=.o)
numbers_test_sources = test_numbers.c numbers.c
numbers_test_objects = $(numbers_test_sources:.c=.o)
bintree_test_sources = test_bintree.c bintree.c
bintree_test_objects = $(bintree_test_sources:.c=.o)
stack_test_runner: $(stack_test_objects)
$(CC) $(FLAGS) $^ -o $@
numbers_test_runner: $(numbers_test_objects)
$(CC) $(FLAGS) $^ -o $@
unitTests: stack_test_runner numbers_test_runner
bintree_test_runner: $(bintree_test_objects)
$(CC) $(FLAGS) $^ -o $@
unitTests: stack_test_runner numbers_test_runner bintree_test_runner
@echo "============================="
@echo "Running Unit Tests..."
@echo "============================="
./stack_test_runner
./numbers_test_runner
./bintree_test_runner
@echo "============================="
@echo "Unit Tests Finished."
@echo "============================="

View File

@ -78,7 +78,7 @@ unsigned int *createNumbers(unsigned int len)
array[i] = rand() % (2*len) + 1;
}
//TODO: sicherstellen, dass im Array keine doppelten Zahlen vorhanden sind (Max)
position = rand() % len;
duplicate_value = array[position];
@ -86,7 +86,7 @@ unsigned int *createNumbers(unsigned int len)
do
{
pos_dup = rand() % len;
} while (pos_dup = duplicate_value);
} while (pos_dup == position);
array[pos_dup] = array[position];

BIN
numbers.o

Binary file not shown.

BIN
timer.o

Binary file not shown.