diff --git a/maths/iterative_pair.py b/maths/iterative_pair.py index f113ced55..369cff26d 100644 --- a/maths/iterative_pair.py +++ b/maths/iterative_pair.py @@ -1,19 +1,5 @@ -import math -import os -import random -import re -import sys -from collections import Counter import doctest - -# -# Complete the 'sockMerchant' function below. -# -# The function is expected to return an INTEGER. -# The function accepts following parameters: -# 1. INTEGER n -# 2. INTEGER_ARRAY ar -# +from collections import Counter def sockMerchant(n, ar): @@ -35,9 +21,9 @@ def sockMerchant(n, ar): if __name__ == "__main__": - n = int(input("Enter length of array:- \n").strip()) + n = int(input().strip()) - ar = list(map(int, input("Enter the elements: \n").rstrip().split())) + ar = list(map(int, input().rstrip().split())) result = sockMerchant(n, ar) print(result)