#๐Ÿ”’ Input and if problems

26 messages ยท Page 1 of 1 (latest)

wraith pollenBOT
#

@broken willow

Python help channel opened

Remember to:

  • Ask your Python question, not if you can ask or if there's an expert who can help.
  • Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
  • Explain what you expect to happen and what actually happens.

:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.

broken willow
#

print("What is the best DDLC charchter?")
name=input("")

if name==("Sayori"):
print("No that's the wrong answer you need rope to stay commited to.")

elif name=="Natsuki":
print("Natsuki don't make me laugh she's clearly not the best one")
print("What do you think about that")
input=("Do you have anything to say about that huh?")

input==(""): print("Weird no response obviously that means you know I'm rigth, rigth?")

else:
print("Fuck you eats your cupecake!!!")

#

This is my code

bleak moss
#
print("What is the best DDLC charchter?")
name=input("")


if name==("Sayori"):
   print("No that's the wrong answer you need rope to stay commited to.")

elif name=="Natsuki": 
   print("Natsuki don't make me laugh she's clearly not the best one") 
   print("What do you think about that")
   input=("Do you have anything to say about that huh?")

input==(""): print("Weird no response obviously that means you know I'm rigth, rigth?")

else:
 print("Fuck you eats your cupecake!!!")
#

use code blocks please

#

your input is incorrect its a built in

#

so for example to get the users input youd want something along the lines of:

response = input("Do you have anything to say about that?")
#

then what you could do is check the response something like:

    if response == "":
        print("Weird no response obviously that means you know I'm right, right?")
broken willow
#

But the syntax doesen't work for me on else:

#

What should I do also what defines a codeblock in Python

bleak moss
#
print("What is the best DDLC character?")
name = input("")

if name == "Sayori":
    print("No that's the wrong answer you need rope to stay committed to.")

elif name == "Natsuki":
    print("Natsuki don't make me laugh she's clearly not the best one")
    print("What do you think about that?")
    response = input("Do you have anything to say about that huh? ")
    if response == "":
        print("Weird no response obviously that means you know I'm right, right?")

else:
    print("Fuck you eat your cupcake!!!")
#

your indentation is all whacked

broken willow
#

What is indentation?

bleak moss
broken willow
#

ohh why does python wan't it in that order (only curios)

#

I wan't to learn as much as possible

broken willow
# bleak moss

Also what happend with input beetwen pic 1 and 2 Where should I put it? :3

bleak moss
#
print("What is the best DDLC character?")
name = input("")

if name == "Sayori":
    print("No that's the wrong answer you need rope to stay committed to.")

elif name == "Natsuki":
    print("Natsuki don't make me laugh she's clearly not the best one")
    print("What do you think about that?")
    response = input("Do you have anything to say about that huh? ")
    if response == "":
        print("Weird no response obviously that means you know I'm right, right?")

else:
    print("Fuck you eat your cupcake!!!")
broken willow
#

Okay thx so much your quick at this ๐Ÿ™‚

bleak moss
#

20+ years of doing it ๐Ÿ˜›

broken willow
#

Do you work with it?

#

Beacause that's what I wan't to do in the future ๐Ÿ™‚

wraith pollenBOT
#
Python help channel closed

This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.

#

๐Ÿ”’ Input and if problems