Created
March 16, 2013 21:34
-
-
Save wsoczynski/5178414 to your computer and use it in GitHub Desktop.
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
public class Sample { | |
public List<Double> allEvenNumberToSecondPower(List<Integer> input) { | |
List<Double> result = new LinkedList<Double>(); | |
for (Integer item : input) { | |
if (item % 2 == 0) { | |
result.add(Math.pow(item, 2)); | |
} | |
} | |
return result; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment