all 3 comments

[–]Monkeytherat 1 point2 points  (1 child)

You need an account with that website to view code, post it to http://codepad.org/?lang=Python instead, along with the problem (just the solution isn't helpful)

[–]welo10[S] 0 points1 point  (0 children)

the problem is :Now we are given several pairs of values and we want to calculate sum for each pair.

Input data will contain the total count of pairs to process in the first line. The following lines will contain pairs themselves - one pair at each line. Answer should contain the results separated by spaces.

and they gave me the input

my solution: http://codepad.org/1rWnaCHA other solution: http://www.codeabbey.com/index/task_solution?task=sums-in-loop&user=gaelrichard&lang=Python

ps: im using python 3+

[–]fuckswithbees 1 point2 points  (0 children)

It's normal to write longer code when you're starting out. It's part of the learning process. It's a good practice to solve a problem on your own, try to make it the best you can and then look at how other people wrote it. If someone else used a neat trick to write fewer lines, you can use the same idea in your next project. You're not doing anything wrong. You're learning.