my bash script file is working fine as user test cases suggest but can not pass some user test is the link:-GitHub - aynuayex/build-a-number-guessing-game

something is wrong with the image you have posted. it appears unreadably dark.

you can zoom it to make it clear.

I think i should change the topic to freecodecamp support.because no one replied and the bash script code works perfectly fine as test cases suggest.At the last project how such kind of problem happens to me ,i am frustrated and exhausted :triumph: :face_exhaling: :confounded:

the problem was my code is not efficient and when I run it ,time runs out.I solved it by refactoring my code.but freecodecamp staff members should consider this type of case or they should emphasize that your code should be efficient .

How did you discover the inefficiencies?

I investigate the topic similar to mine and from the replies some one mentioned this thing and I realize that I have the same problem even worst because i was storing each guess in a table and quering it every time how much i have guessed.

ah! So instead of storing the guesses, you just went with regular script code to add them up then stored the final guess only.
Thanks for clarifying.

Yes, of course, I did that and it worked!

1 Like