Maria Caicedo’s Code
Maria’s version was really clean to read, which made going through her logic easier. Variable names were on point – stuff like secretWord, guessedLetters, and numberOfHints made it super clear what was going on without needing extra explanations. She did include Javadoc comments for most methods, although I saw a couple TODO comments and some placeholders like //FIX THIS – probably stuff she meant to get back to later. The core logic worked well though, and the methods followed the assignment spec closely.
One thing I appreciated was how well her chooseWord() and makeGuess() methods worked with the test file. All the unit tests passed, so that’s a good sign that the implementation is solid. There were no extra imports or unused stuff hanging around either. One small thing – in getHint(), she checks if (!guessedLetters.contains(currentChar)), but guessedLetters is a list of String, so comparing with a char might be inconsistent. It didn’t break the tests though, which is kind of wild.
Ysabelle Kim’s Code
Ysabelle’s code looked really complete. Her use of helper methods and clear separation of responsibilities made the structure feel tight. She used a List<Character> for guessed letters, which I think is actually a little better than using a list of strings (like Maria did), because it avoids confusion when comparing characters.
One thing that stood out was how methodical her readFile() implementation was – she even mentioned how nextLine() shouldn't be called multiple times, which shows she really paid attention to the details. The variable names were consistent, and she had setters for a lot of values, which added flexibility. She also made use of debug prints well, and nothing seemed out of place or unfinished. No unused imports either.
Unit tests passed just fine, and her implementation didn’t mess with the test file format or logic. Overall, it felt like a solid and polished submission, and it didn’t try to do more than it needed to.
Stanislav Permiakov’s Code
Stanislav’s version was maybe the cleanest in terms of logic flow. The chooseWord method, for example, felt really complete – like he covered edge cases, added early exits, and used Random in a reliable way to avoid getting stuck in a loop. He also remembered to close the scanner in readFile(), which I forgot the first time I wrote mine, so props for that.
Some of the comment sections were still placeholder (like the author and date), but the actual code worked really well. He didn’t overcomplicate the design, and it followed the test expectations perfectly. I noticed that his guessed letters were also stored as characters, not strings, which helped when checking against the secret word.
No extra imports, formatting was clean, and naming was clear. If anything, I think he could’ve added a couple more comments in key methods, just to explain his thinking. But from what I saw, everything functioned right and unit tests all passed without changes.
Overall Thoughts
One thing I noticed is that all of us had different takes on how to handle guessed letters – Maria used strings, Ysabelle and Stanislav used characters. I think using char directly might be safer and less confusing when comparing to characters in the secret word, so I might update mine to match that.
Another common theme was that everyone passed the unit tests, which honestly surprised me a bit. I thought someone’s implementation might break on edge cases like repeated guesses or invalid input, but nope – all three handled that stuff well.
The hardest test to pass in my own experience was probably the hintTest(). Just because the test requires the hint count to drop and the guessed letter to be valid – and my earlier version didn’t decrement the hint counter properly. After seeing how the others did it, I realize I can simplify my version a bit and make it more readable.
Something I struggled with was writing the makeGuess() method cleanly – I rewrote it a couple times before I got it working. It’s easy to mess up the part where you’re updating the guessedWord string and tracking score at the same time. I noticed Ysabelle handled that well with clean if-else logic.
If I had to pick one improvement for my code, it would be to make it more readable and clean like Stanislav’s and maybe structure things better like Ysabelle did. I think I was too focused on just getting the tests to pass and didn’t think about future readability.
My biggest win was getting all the unit tests to pass in the end. It honestly felt like a relief after spending so much time tweaking little things and debugging. Seeing everything pass gave me confidence that my logic held up, even if it wasn’t perfect.