1Numbers = [90,78,34,50,100,99]
2higest_number = 0
3for number in Numbers:
4 if number > higest_number:
5 higest_number = number
1def return_largest_element(array):
2 largest = 0
3 for x in range(0, len(array)):
4 if(array[x] > largest):
5 largest = array[x]
6 return largest
1l=[]
2n=int(input("enter the upper limit"))
3for i in range(0,n):
4 a=int(input("enter the numbers"))
5 l.append(a)
6maxno=l[0]
7i=0
8while i<n:
9 if l[i]>maxno:
10 a=l[i]
11 i=i+1
12 elif l[i]>maxno:
13 b=l[i]
14 i=i+1
15 print("max no is :",b)
16 break
17 else:
18 print("max no is",a)
19 break
20#without using function i am just a beginner
21#need improvement to shorten the code but plz without any function
1n = int(input("Enter number of elements : "))
2l = []
3new=[]
4dope = 0
5for i in range(n):
6 l.append(int(input("Enter a number: ")))
7print(l)
8for i in l :
9 first = i
10 count=0
11 for x in l:
12 if x == first:
13 count+=1
14
15 new.append(count)
16k=new[0]
17print(new)
18for i in new:
19
20 if i >=k:
21 dope = l[i]
22
23
24
25print(dope)
26
27
28
29
30
31