0
How can i put double quotes or single quotes to the input in python? can anyone tell me
While taking input from user, how can i put that input value in single or double quotes
16 Answers
+ 5
Mr. 12 , it would be helpful if you can make a sample how it should look like. Thanks!
+ 3
There are two options that have not yet been shown here:
txt = 'hello world'
print(f'"{txt}"') # output: "hello world"
# or:
print(repr(txt)) # output: 'hello world'
+ 1
Granger i mean,
x = input()
we have given hello world
it will print hello world, just like we typed.
i am asking how can we get "hello world" or 'hello world'.
i am asking how can we put single or double quotes for that hello world. it has to print like this
0
Granger bro,it is not working
0
Granger it is also not working bro
0
Input ("tell me your name")
Name= blooming
Print (input )
hope it helps....and if any error is there please tell so that I can correct it coz I'm a beginner.
- 1
blooming Flowers that is not what i asked their
- 1
OK so u are asking how can u put double quotes in print ().
- 1
- 1
OK. I'm sorry that I can't able to help.