Skip to content

Instantly share code, notes, and snippets.

View shicholas's full-sized avatar
🏁
small victories add up

nick shicholas

🏁
small victories add up
  • Earth
View GitHub Profile
@shicholas
shicholas / string_calculator.rb
Last active December 18, 2015 15:49
LVRUG Kata 6/19/13 with many thanks to @marksim
module StringCalculator
String.class_eval do
def calc
raise NoNegativeNumbers.new(numbers.select{|n| n < 0}) if numbers.any?{|n| n < 0}
numbers.inject(0, &:+)
end
private
@shicholas
shicholas / bowling.rb
Created June 4, 2013 03:58
Pair Programming Session w/ @marksim
class Bowling
def initialize
@rolls = []
end
def roll(pins)
@rolls << pins
end
@shicholas
shicholas / circle.yml
Last active December 17, 2015 14:09
circle.yml for rails and yeoman
## Customize the test machine
machine:
timezone:
America/Los_Angeles # Set the timezone
# Version of ruby to use
ruby:
version:
1.9.3-p392