Skip to content
Sign upLog in

Not Sure Why This isn't working?

Profile icon
1Dagree

Its not completed but it just keeps repeating same thing and i did not program it to do that can someone help

You are viewing a single comment. View All
Profile icon
BenjaminNamikas

lol. the problem is that you put all the code for people guessing and for you to guess in the else statement, so it skips it if you are the mafia and the loop repeats and prints you are the mafia.

Please upvote or mark that this is the answer if it has helped/ given you the answer

Profile icon
1Dagree

@BenjaminNamikas
Its going to have some different code to the what's in the else statement

Profile icon
BenjaminNamikas

@Uzalii
oh then what is the problem

Profile icon
1Dagree

@BenjaminNamikas
I don't seem to die even if every1 votes for suspect 4 (which is you) when I am not the mafia

Profile icon
BenjaminNamika1

@Uzalii
That is because you check if anyone thinks if it is you then you get one, even if there are multiply, so if they all think it is you you get one point, and if you suspect anyone else then they will get one point and you won't die because you are not greater that everybody else