Skip to content

Instantly share code, notes, and snippets.

@blake41
Created November 19, 2013 13:46
Show Gist options
  • Save blake41/7545587 to your computer and use it in GitHub Desktop.
Save blake41/7545587 to your computer and use it in GitHub Desktop.
def first_even(items)
#code goes here
end
require_relative "even_solution"
describe "first even" do
it "should return the first even number in an array" do
first_even([30, 17, 77, 102]).should eq(30)
end
it "should return the first even number in an array" do
first_even([5, 11, 50]).should eq(50)
end
it "should return the first even number in an array" do
first_even([3, 5, 15, 16, 23, 42]).should eq(16)
end
it "should return the first even number in an array" do
first_even([300, 22, 1, 55, 42]).should eq(300)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment