Q. Write a program to check if a number is present in the list or not. If the number is present, print the position of the number. Print an appropriate message if the number is not present in the list.
Answer =
lst = eval(input("Enter first list :-")) num = int(input("Enter the number which you want to search :-")) if num in lst : print(lst.index( num ) ) else : print("Number not found")
hi
ReplyDeletehi
ReplyDeletebyee
DeleteHello thank you for your help and your hardwork keep it up and I will also give my best studying through your site once again thank you ☺️
ReplyDeletePost a Comment
You can help us by Clicking on ads. ^_^
Please do not send spam comment : )