Questions and Answers
Problems and Solutions
Quotes help make search much faster. Example: "Practice Makes Perfect"
Thursday, January 17, 2013
Codecademy Sample Solution: Proc Syntax
floats = [1.2, 3.45, 0.91, 7.727, 11.42, 482.911]
# Write your code below this line!
round_down = Proc.new {|num| num.floor }
# Write your code above this line!
ints = floats.collect(&round_down)
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
This is an example of
scrolling text
using Javascript.
Popular Posts
No comments:
Post a Comment