+ 1

I dont understand what is wrong

Pi = 3.14 user.input( :) = R P = 2*Pi* R E = Pi*(R*R) print(E,P)

11th May 2020, 6:16 PM
sofronis
sofronis - avatar
14 odpowiedzi
+ 4
user.input( :)??? try int(input()) instead
13th May 2020, 1:55 PM
Mehnaz ✨
Mehnaz ✨ - avatar
+ 3
sofronis If I remember correctly, when you run it directly as .py, it will quickly run and then quit and close. You may need to put a pause in the question by putting an input () at the end of the program.
11th May 2020, 6:33 PM
Frenchtoast
Frenchtoast - avatar
+ 3
Replace-: user.input( :) = R By-: R = float(input ("Enter Radius")) You can also use 'int' in place of 'float'.
13th May 2020, 1:06 PM
Manisha Kumari
Manisha Kumari - avatar
+ 1
Pi = 3'14 R = flot(input( )) P = 2*Pi*R E = Pi*(R^2) print( P ) print( E )
13th May 2020, 2:38 PM
eduardo palou jaume
eduardo palou jaume - avatar
+ 1
It is so easy Pi =3.14 R=float(input()) P=2*Pi*R E=Pi*R**2 print (P) print (E)
13th May 2020, 5:46 PM
Sâñtôsh
Sâñtôsh - avatar
0
𝐊𝐢𝐢𝐛𝐨 𝐆𝐡𝐚𝐲𝐚𝐥 how did i come up with user.input , thats so weird 😂
11th May 2020, 6:24 PM
sofronis
sofronis - avatar
0
𝐊𝐢𝐢𝐛𝐨 𝐆𝐡𝐚𝐲𝐚𝐥 when i try to open the file in .py it closes after 1 second, do you know why?
11th May 2020, 6:28 PM
sofronis
sofronis - avatar
0
𝐊𝐢𝐢𝐛𝐨 𝐆𝐡𝐚𝐲𝐚𝐥 and finally, when i press enter , one answer is next to input and the other next line, i want them both on new lines, how do i do it with \n
11th May 2020, 6:32 PM
sofronis
sofronis - avatar
0
@Kiibo Ghayal Pi = 3.14 R = int(input("Εισάγεται την ακτίνα του κύκλου:")) P = 2*Pi* R E = Pi*(R*R) print(E) print(R) Εισάγεται την ακτίνα του κύκλου:78.5 5
11th May 2020, 6:35 PM
sofronis
sofronis - avatar
0
@Kiibo Ghayal i want the 78.5 and 5 to be on different lines ex: Εισάγεται την ακτίνα του κύκλου: 78.5 5
11th May 2020, 6:40 PM
sofronis
sofronis - avatar
0
Input line its wrong
12th May 2020, 9:56 PM
Jean
Jean - avatar
0
Print(str(E)+"\n"+str(R))
12th May 2020, 11:00 PM
Theophilus Alloys Yankah
Theophilus Alloys Yankah - avatar
0
If the issue is just to make it split into two lines, you can just add "/n" at the end of the text insde the input method
13th May 2020, 7:24 AM
Diego Serrano Gómez
Diego Serrano Gómez - avatar
0
The second line is wrong. The valid way to declare an input in your case is: R=int (input ())
13th May 2020, 5:45 PM
Bedaly Tacky
Bedaly Tacky - avatar