Ask coding questions

← Back to all posts
Why is this not working?
isaiah08

I am working on a python player's handbook encyclopedia for D&D 5e. So far, my code has just been getting stuck on def statements, and not continuing past intro(). What is wrong?

Answered by CodingRobot12 [earned 5 cycles]
View Answer
Voters
isaiah08
Comments
hotnewtop
CodingRobot12

oh it is because main.lower does not have parenthesis so do it like main.lower()

CodingRobot12

The introduction keeps looping because the if-statement is not true so therefore it will keep going back to the introduction.

isaiah08

Yes, thanks! That was the one it was getting stuck on @CodingRobot12

Bookie0

maybe put the function races() above where you called it, so move it above line 7 (like just copy it into line 1)

Hope this helps! =)

isaiah08

Thanks so much! @Bookie0

isaiah08

Oh wait... this wasn't the main issue, but it was definitely an issue. Thanks [email protected]

Bookie0

sure,

please this answer as correct if it helped! =) @isaiah08

Bookie0

sure @isaiah08

isaiah08

Argh, i wish i could say that two people got the right answer. @Bookie0

Bookie0

It’s ok glad to help! ;) @isaiah08

EpicGamer007

Check your indents. Maybe that would work.