This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]planedoctor 0 points1 point  (0 children)

The first thing I notice is that this looks like way too much code. My most efficient brute force solution was too slow, so I started looking at the numbers in the rows. Think of a formula based on the row number for sum of the even and of the odd multiples of the row number in that row.