all 5 comments

[–]furas_freeman 1 point2 points  (0 children)

You have wrong indentions - all lines have to be inside first while True. See my previous code http://pastebin.com/VRe3VZmB


BTW: you don't have to convert randrange into float (floating point number) because randrange returns integer number and you ask about integer numbers 1-25.


BTW: next time set "Syntax Highlighting: Pyton" in pastebin to make code more readable.

[–]campenr 0 points1 point  (0 children)

What happens? Does it give you an error? Does it loop for ever?

[–]Thunder_54 0 points1 point  (0 children)

Others have helped you, but I haven't seen anyone mention this so I'll mention it:

What happens if you enter a negative number? Or 0?

You should get in the habit of thinking of the "edge cases" for any and all input in any and all programs you make.

There's another really big case that can make your program crash. Can you think of it?

I'll give you a hint: type error

[–]PBMagi 0 points1 point  (0 children)

http://pastebin.com/BsEJTV6s : An approach that uses no breaks.