Learn practical skills, build real-world projects, and advance your career
!pip install jovian --upgrade --quiet
import jovian

Question 1: The user will enter a list of numbers and a separate number. The program will display the index at which the number is present in the list. If the number is absent, it'll return -1. Do NOT use built-in functions for searching.

num= int(input('enter number here my nigga:'))
numlist=[]
morenum=True
while morenum:
    inputnum=input("enter numbers to be entered in list one by one here(click only enter if there is nothing to add):")
    if (inputnum==''):
        morenum=False
    else:
        numlist=numlist+[int(inputnum)]
print(num)
print(numlist)
found=False
for i in numlist:
    if i==num:
        found=True
        print("index of num=",numlist.index(i))
        break
if not found:
    print("-1")