5. A list namely Adm stores admission numbers of 100 students in it, sorted in ascending order of admission numbers. Write a program that takes an admission number and looks for it in list Adm using binary search technique. The binary search function should use recursion in it.
def adm_search(arr, x, f=0, l=10): if l >= f: mid = (f+l)//2 if arr[mid] == x: # Found return mid elif arr[mid] > x: return adm_search(arr, x, f, mid-1) # search below else: return adm_search(arr, x, mid+1, l) # search above else: return ‘Not Found’ # adm list can be of any number adm = […]