Why Did I Fail My Coding Interview Challenge?

0
0
Asked By CuriousCoder88 On

So I recently applied for a consultant/backend Java developer position and was given a coding challenge where I had to create a slot machine that works through REST calls using JSON. The game costs 3 credits to play, and players win based on the fruits shown on the reels. I received feedback saying I had great personality and consulting skills, but my technical work didn't meet their expectations. Now I'm wondering what exactly went wrong. Here are the details and links to my project repository and the API documentation. Any insights would be really appreciated!

5 Answers

Answered By InsightfulIsaac On

From what I've seen, your code looks decent overall, but be sure to adhere to proper gambling regulations in your implementation. Companies are often picky about specifics like these. Plus, remember there's always a chance they preferred another candidate's work over yours without any specific faults in yours!

Answered By DebuggerDude On

Just a heads up: sometimes coding challenges don't reflect the true reason for rejection. They might have concerns based on your resume or other factors unrelated to the code itself. Keep that in mind when evaluating the feedback you received!

CuriousCoder88 -

I just wish they could've been more specific about what they didn't like!

Answered By CleverCoder On

You might want to improve your testing approach. It seems like you focused on integration tests instead of unit tests. Those are crucial for validating individual components. Additionally, the organization of your game logic could be clearer; for instance, separating money management logic from the game logic would be more effective!

CodeMaster24 -

Definitely! A cleaner structure could make a huge difference in how the code is understood and tested.

Answered By DevDiva101 On

Be careful with how you handle payouts. Implementing a dynamic bet can lead to major issues, like giving players unfair advantages over the house, which is a huge red flag in a real casino scenario. It's crucial to ensure the payouts are balanced and within reasonable limits!

SyntaxSam -

Right? Balancing that house edge is really important in gambling-related code!

Answered By TechieTom On

One big issue I noticed is that while the game is supposed to cost a minimum of 3 credits, you designed it so players can bet more than that, which goes against the task requirements. Also, the way you calculate different payouts isn't clear, and I think it lacks proper unit tests. For instance, you should have tests confirming that 3 apples yield 10 credits. Just ensuring those core functionalities are tested would help a lot!

CodeNerd99 -

Yeah, I agree! It’s super important to make sure your basics are clearly defined and tested before you add any extra features.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.