fixed iterative_pair.py

This commit is contained in:
souvikghosh05 2021-11-03 21:53:19 +05:30
parent 88de7ccff5
commit 5b114c5db5
No known key found for this signature in database
GPG Key ID: 1CE1EF8556B0B862

View File

@ -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)