We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 88de7cc commit 5b114c5Copy full SHA for 5b114c5
maths/iterative_pair.py
@@ -1,19 +1,5 @@
1
-import math
2
-import os
3
-import random
4
-import re
5
-import sys
6
-from collections import Counter
7
import doctest
8
-
9
-#
10
-# Complete the 'sockMerchant' function below.
11
12
-# The function is expected to return an INTEGER.
13
-# The function accepts following parameters:
14
-# 1. INTEGER n
15
-# 2. INTEGER_ARRAY ar
16
+from collections import Counter
17
18
19
def sockMerchant(n, ar):
@@ -35,9 +21,9 @@ def sockMerchant(n, ar):
35
21
36
22
if __name__ == "__main__":
37
23
38
- n = int(input("Enter length of array:- \n").strip())
24
+ n = int(input().strip())
39
25
40
- ar = list(map(int, input("Enter the elements: \n").rstrip().split()))
26
+ ar = list(map(int, input().rstrip().split()))
41
27
42
28
result = sockMerchant(n, ar)
43
29
print(result)
0 commit comments