Advertisement
suryadharani

Day1

Nov 24th, 2022
390
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.24 KB | Source Code | 0 0
  1. import math
  2. def divide_or_square(num):
  3.     if num%5==0:
  4.         print(num," is divisible by 5 and its square root is ",math.sqrt(num))
  5.     else:
  6.         print(num , " is not divisible by 5 leaving a remainder of ", num%5)
  7.  
  8. divide_or_square(int(input()))
  9.  
Tags: python
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement