Created
May 11, 2022 09:13
-
-
Save washingtonsoares/c499a18094c3250dbb76b965d24544f7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://www.beecrowd.com.br/judge/pt/problems/view/1168 | |
n = int(input()) | |
ledsByValue = { | |
"0": 6, | |
"1": 2, | |
"2": 5, | |
"3": 5, | |
"4": 4, | |
"5": 5, | |
"6": 6, | |
"7": 3, | |
"8": 7, | |
"9": 6, | |
} | |
for _ in range(n): | |
value = input() | |
sum = 0 | |
for number in value: | |
leds = ledsByValue[number] | |
sum += leds | |
print(str(sum) + " leds") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment