It's now here, in The Programmer's Compendium. The content is the same as before, but being part of the compendium means that it's actively maintained.
This file contains hidden or 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
# Opinionated instructions for setting up a laptop for development at Carbon Five. | |
# Not intended to be run wholesale; read, interpret, tweak (maybe), then run piece by piece. | |
# | |
# Tested against Yosemite 10.10. | |
#-------------------------------------- | |
# Install Homebrew. | |
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" |
This file contains hidden or 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
# For RubyQue question: http://rubeque.com/problems/home-on-the-range | |
def find_range | |
min = 0 | |
default_max = 99 | |
max = default_max | |
goal = 4494 | |
while min <= max | |
current_sum = (1..100).to_a[min..max].reduce(:+) | |
if current_sum == 4494 |