aboutsummaryrefslogtreecommitdiff
path: root/challenge-322/eric-cheung/python/ch-2.py
blob: bc975d09a799b609f63fa43c149f1ae54db003f2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
## arrInts = [55, 22, 44, 33]  ## Example 1
## arrInts = [10, 10, 10]  ## Example 2
arrInts = [5, 1, 1, 4, 3]  ## Example 3

arrSet = sorted(set(arrInts))

## print (arrSet)

arrOutput = [arrSet.index(nLoop) + 1 for nLoop in arrInts]

print (arrOutput)