For this Question: Given two sorted arrays A and B of size n and m respectively, return the median of the two sorted arrays.The first line of input contains n, m the length of arrays A and B.
The next two lines contain the input of arrays A and B.

<b>Constraints</b>
1 &le; n, m &le; 1000
-10<sup>6</sup> &le; A[i], B[i] &le; 10<sup>6</sup>Print the median of two sorted arrays upto two decimal places.Sample Input : 
2 1
1 3
2

Sample Output :
2.00, I have written this Solution Code: def getMedian(arr1, arr2, n, m):
    i=j=0
    sort=[]
    while i<n and j<m:
        if arr1[i] < arr2[j]:
            sort.append(arr1[i])
            i+=1
        else:
            sort.append(arr2[j])
            j+=1
    while i<n:
        sort.append(arr1[i])
        i+=1
    while j<m:
        sort.append(arr2[j])
        j+=1
    if (n+m)%2==1:
        ind=(len(sort)//2)+1
        num=sort[ind-1]
    else:
        mid=len(sort)//2
        num=(sort[mid-1]+sort[mid])/2
    return num
n, m= input().split()
n, m= int(n),int(m)
ar1=list(map(int, input().split()))
ar2=list(map(int, input().split()))
print("%.2f" %getMedian(ar1, ar2, n, m)), In this Programming Language: Python, Now tell me if this Code is compilable or not?