Skip to main content

Code #11 Speak Function

                GREETINGS TO ALL YOU!!!! This is text to speak converter Function from  win32com.client  import  Dispatch def   speak (str):     speak = Dispatch( "SAPI.spVoice" )     speak.Speak( str ) if  __name__  ==   "__main__" :     speak("# your text goes here")

Code#6 finding square by python

GREETINGS TO ALL OF YOU!!!!!!!

WE WILL MAKE A PROGRAM TO IDENTIFY THAT THE GIVEN INPUT IS A PERFECT SQUARE OR NOT A PERFECT SQUARE... 

WE WILL BE USING MATH MODULE 

WE HAVE TO IMPORT MATH MODULE 


SO LETS START WITH IT!!!!!!!


import math

print("welcome to square root finding tool")
i=int(input("enter your number "))
a=math.sqrt(i) # it will find the square of i that is the number given by the user
#when we find square root in python it gives the result in decimal(.)
if (a-math.floor(a)==0):

print("it is a perfect square:",i)
else:
print("it is not a perfect square: ",i)

THANK YOU !!!!!!!

Comments