30-Days-Of-Python
30-Days-Of-Python copied to clipboard
number printing mistake
here 03_operators.md inside example-number part on the very last part there print('Exponentiation: ', 2 ** 3) # 9 it means 2 * 2 * 2 it should be # 8 it means 2 * 2 * 2
print('Addition: ', 1 + 2) print('Subtraction: ', 2 - 1) print('Multiplication: ', 2 * 3) print ('Division: ', 4 / 2) # Division in python gives floating number print('Division: ', 6 / 2) print('Division: ', 7 / 2) print('Division without the remainder: ', 7 // 2) # gives without the floating number or without the remaining print('Modulus: ', 3 % 2) # Gives the remainder print ('Division without the remainder: ', 7 // 3) print('Exponential: ', 3 ** 2) # it means 3 * 3
Look, it's 3**2 which is 3*3 which 9, so no mistake, it's correct
print('Addition: ', 1 + 2) print('Subtraction: ', 2 - 1) print('Multiplication: ', 2 * 3) print ('Division: ', 4 / 2) # Division in python gives floating number print('Division: ', 6 / 2) print('Division: ', 7 / 2) print('Division without the remainder: ', 7 // 2) # gives without the floating number or without the remaining print('Modulus: ', 3 % 2) # Gives the remainder print ('Division without the remainder: ', 7 // 3) print('Exponential: ', 3 ** 2) # it means 3 * 3Look, it's 3**2 which is 3*3 which 9, so no mistake, it's correct
yes you are right my bad i didn't mentioned that i am reading from .md file not from .py so there is in md file printing mistake is there !