Created
April 18, 2013 11:38
-
-
Save lauripiispanen/5412081 to your computer and use it in GitHub Desktop.
Java y u no lambda? :(
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 String getDays() { | |
String ret = ""; | |
for (int i = 0; i < days.size(); i++) { | |
if (i > 0) { | |
ret += ", "; | |
} | |
ret += days.get(i); | |
} | |
return ret; | |
} | |
---- | |
def getDays = days.join(", ") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment