46. Python Program to find a number Existing given Array of Numbers or Not.
How does this program work?
- In this program we are going to learn about how to find whether the given number is existing in array or not using Python.
Here is the code
ar = ((5,6,7,8,9))
print("Array of numbers: ")
print(ar)
a = int ( input("Enter the number you want to check in an array: "))
if a in ar:
print("Number is existed")
else:
print("Number is not existed")