#include "include/challenges.h" char genChallenge(int fd, char * output, challenge_t challenge) { printf("%s\n", challenge.message); int readChars; readChars = read(fd, output, MAX_LEN - 1); if (readChars < 0) printSystemError("Challenges: read()"); output[readChars] = '\0'; printf("%s\n", challenge.question); return strcmp(output, challenge.flag); }