Create a program using the following features:
* Array
* Class
* Specific Sorting Algorithm
* Specific Searching Algorithm
class Test:
def Searching(*arr):
elem= arr[1]
if elem in arr[2]:
return "Yes"
else:
return "No"
def Sorting(*arr):
arr[1].sort()
return arr[1]
inp = [10,9,8,7,6,5,4,3,2,1]
t1 = Test()
print(t1.Searching(5,inp))
print(t1.Searching(13,inp))
print(t1.Sorting(inp))
Comments
Leave a comment