+ 4
there is a sing to a square root in Python?
if there isn't, what should I write?
8 Antwoorden
+ 2
I -_- D :
10**2 = 100
100**0.5 = 10
5**2 = 25
25**0.5 = 5
https://code.sololearn.com/cUSTbD3gh6Lj/?ref=app
+ 6
Ulisses Cruz thank you.
+ 3
try:
x**.5
+ 3
Ulisses Cruz Louis I didn't understood both of you.
+ 2
I -_- D
if you have a number in a variable 'x'
and you want to take the square root of 'x'
just do it like this:
sqrt_root_of_x = x**0.5
+ 2
Ulisses Cruz can you use google translation?
ืืฉืื ื ืืืชื ืืช ืื ืืืืืง ืืื ืฉืืชืืช, ืื ืืฉ ืืืืืฉืื ืืขืื, ืื ืืืืข ืืืื ืืืืืง.
ืืื ืื ืื ืืื ืืจืืจ, ืืืื ืืชืจืืื, ืืชืืืื ืชื ืืฉืืจืฉ, ืืืืืื: ืฉืืจืฉ ืฉื 25 ืื 5. ืืฉืืจืฉ ืฉื 100 ืื 10. (10**2=100)
+ 1
x**.5
or
from math import sqrt
sqrt(x) i think
0
you may be interested in the timed versions of sqrt
https://code.sololearn.com/cdyYLvewbn3J/?ref=app