print(sum(map(int, map(input, range(int(input()))))))
3 10 22 68
012100
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!