#include #include "input.h" #define MAX_WORDS 100 #define MAX_WORD_LEN 20 int main() { FILE *file = fopen("words.txt", "r"); if (!file) { perror("Datei konnte nicht geöffnet werden"); return 1; } char words[MAX_WORDS][MAX_WORD_LEN]; int wordCount = readWords(file, words, MAX_WORDS); fclose(file); printf("Es wurden %d Wörter eingelesen:\n", wordCount); for (int i = 0; i < wordCount; i++) { printf("%s\n", words[i]); } return 0; }