This file contains 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
/* LINQ Puzzle #24 ******************************************************* | |
Summary: Given a list integers, find the sum of all numbers in list where the index of | |
the number equals the number at that index | |
Sample: { 6, 5, 4, 3, 2, 1, 6 } => 9 | |
{ 0, 1, 1, 3 } => 4 | |
************************************************************************/ | |
var input = new [] { 6, 1, 5, 2, 4, 8, 7, 7, 2, 6, 10 }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment