I hereby claim:
- I am jacortinas on github.
- I am jacortinas (https://keybase.io/jacortinas) on keybase.
- I have a public key ASAJ3peUnQ7WlOpCTUJslbbpmKQky-j9NQCyrbFu_N5nNwo
To claim this, I am signing this object:
| # No gems, just plain Ruby 3. Assumes inputs are in an inputs folder or something. | |
| # Each line is a line or multiline input in an IRB prompt. | |
| # Day 1 | |
| values = IO.readlines("inputs/1.txt").map(&:to_i) | |
| # Part 1 | |
| values.each_cons(2).filter_map { |(a, b)| b > a }.count | |
| # Part 2 |
I hereby claim:
To claim this, I am signing this object:
| $(function() { | |
| $(document).foundation('joyride', { | |
| cookieMonster: true, | |
| cookieName: 'tour', | |
| cookieExpires: 365 * 5, | |
| postRideCallback: function() { | |
| alert('yeah'); | |
| console.log(arguments); | |
| } | |
| }); |
| class User | |
| def follow_default_users | |
| default_user_emails = ['vulume@vulume.com'] | |
| default_user_emails.each do |email| | |
| follow_with_email!(email) | |
| end | |
| end | |
| def follow_with_email!(email) |
| class Name | |
| def initialize name='' | |
| @name = name | |
| end | |
| def name | |
| @name ||= @name.to_s | |
| end | |
| alias :full :name |
| class InvitationRequest | |
| extend ActiveModel::Naming | |
| include ActiveModel::Conversion | |
| include ActiveModel::Validations | |
| include ActiveModel::Serializers::JSON | |
| attr_reader :email, :url | |
| attr_writer :clock, :invitation_class, :mailer | |
| validates :email, presence: true |
| # app/models/user/authentication.rb | |
| require 'bcrypt' | |
| class User | |
| # Password authentication related methods and utilities. | |
| module Authentication | |
| extend ActiveSupport::Concern | |
| module ClassMethods |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/psych.bundle: warning: already initialized constant ANY | |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/psych.bundle: warning: already initialized constant UTF8 | |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/psych.bundle: warning: already initialized constant UTF16LE | |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/psych.bundle: warning: already initialized constant UTF16BE | |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/psych/nodes/stream.rb:12: warning: already initialized constant ANY | |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/psych/nodes/stream.rb:15: warning: already initialized constant UTF8 | |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/psych/nodes/stream.rb:18: warning: already initialized constant UTF16LE | |
| /Users/jacortinas/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/psych/nodes/stream.rb: |
| redis_instance.pipelined do | |
| [1,2,3].each do |item| | |
| redis_instance.sadd 'some_key', item | |
| end | |
| end |
| require 'rubygems' | |
| require 'spork' | |
| Spork.prefork do | |
| # Loading more in this block will cause your tests to run faster. However, | |
| # if you change any configuration or code from libraries loaded here, you'll | |
| # need to restart spork for it take effect. | |
| ENV["RAILS_ENV"] ||= 'test' | |
| require File.expand_path("../../config/environment", __FILE__) | |
| require 'rspec/rails' |