Skip to content

Commit 20a4577

Browse files
authored
Add a soution of ProjectEuler Problem 13
1 parent dc5c576 commit 20a4577

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

Project Euler/Problem 13/sol1.py

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
'''
2+
Problem Statement:
3+
Work out the first ten digits of the sum of the N 50-digit numbers.
4+
'''
5+
6+
n = int(input().strip())
7+
8+
array = []
9+
for i in range(n):
10+
array.append(int(input().strip()))
11+
12+
print(str(sum(array))[:10])
13+

0 commit comments

Comments
 (0)