Timeline for Hangman v2 written in C
Current License: CC BY-SA 4.0
4 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jan 18, 2019 at 17:47 | comment | added | chux |
@Faraz I found count_missing_letters(char **word_to_guess, ...) confusing from the start. Perhaps it is the loose usage of the word here. For me a word would be a char * . Here word is a list of pointer to a letter. Consider Edward idea of "employ a bool array of the same length to keep track of which letters of the alphabet had been guessed". IMO, the word to guess should be const and variables descend from that. Consider a struct hangman { const char *word_to_guess; bool *guessed; size_t word_length; size_t guessed_right_count; size_t guess_count } .
|
|
Jan 18, 2019 at 16:22 | comment | added | Faraz | I am curious to hear your thoughts on count_missing_letters. Is this a clean way to express what is happening? | |
Jan 18, 2019 at 15:42 | history | edited | chux | CC BY-SA 4.0 |
added 93 characters in body
|
Jan 18, 2019 at 15:26 | history | answered | chux | CC BY-SA 4.0 |