How to make a game for guessing number? thank you!

python

#1

Here is the question is to set a number for user to guess .

and it will give user the range when you guess

like this:

but the computer don t let me pass this . what s wrong with my code?

thank u so much.


#2

Nothing that answers what you ask, but a couple of comments:

eval executes a string.
In other words, it'll do WHATEVER that string says.
Like.. reboot the system.
You were doing what, trying to convert it to int? Do that instead.

Is the submission test telling you why it isn't passing you? You should check that out, whatever it is.

What you posted won't run at all. Make sure that your code is intact when you're showing it to others.

If you just compare your programs behavior to the instructions and any error messages, you should be able to figure out what's wrong. Any small difference is still a difference, get it it the point where you are no longer able to find any differences even if the prize for doing so was a pet unicorn.


#3

I send it to judge system on the Internet and it didn t pass.

So I am confused..

thank u


#4

The input example is only two numbers, you're entering a whole lot more?
You also have output that isn't in the example.


#5

this time:

:cry: :cry: :cry:


#6

Isn't one run supposed to be two numbers of input and one line of output?
That's what your screenshot of the description says innit?
You're still using eval, get rid of that stuff while you're at it.


#7

I think it doesn t want me to do while. now I got 75 pts :joy:

but it is still not right..... :cry:


#8

Compare character by character until it's the same.
Almost is still wrong, no matter how near.


#9

Yes !!I passed it!
I think the problem is the space in the sentence.

thank u so much! :joy: :joy: :joy: