In python. print ( 9 * * ( 1/ 2 ) ) = 3.0
Can anyone explain or iterate this... Please
Chandana M You used back slash instead of divisor operator print (9**(1/2)) Will give 3.0 as output
'**' is the exponentiation operator 9**(1/2) is basically the square root of 9 Since 1/2=0.5, 9**0.5=3.0 (since exponent is a float, the output is a float)
The correct syntax would be: print(9 ** (1/2)) Here, the ** operator is used to calculate the power of a number. In this case, the number 9 is being raised to the power of 1/2, which is the same as taking the square root of 9. The print() function is then used to print the result to the screen. The result of this code would be 3.0, which is the square root of 9. I hope this helps! Let me know if you have any other questions.
Okay Ria... But I want how it gonna work
here ** means, power of or exponent And **1/2 means,root over so,√9 os 3
How do I generate a list with <N> unique elements randomly selected from another (already existing) list?
Given three integer matrices A(m*n),B(m*n) and C(m*n) . Print the one with more zero elements. beside code
I'm coding this for hours & can't make the value of the 5 random numbers round off to 2 decimal places like in the examples
Overloading + operator
( NEED HELP ) Halloween candy