Skip to content

Instantly share code, notes, and snippets.

View rcanand's full-sized avatar

Anand C Ramanathan rcanand

  • MLAI LLC
  • Bellevue, WA, USA
View GitHub Profile
from sympy import sieve
def goldbach():
'''
For each even number > 2,
it finds a pair of two primes that add up to the number
'''
even = 4
@rcanand
rcanand / gist:ac898e53068979b09231
Created August 25, 2015 03:18
bundle list for fontawesome issue
Gems included by the bundle:
* actionmailer (4.2.3)
* actionpack (4.2.3)
* actionview (4.2.3)
* activejob (4.2.3)
* activemodel (4.2.3)
* activerecord (4.2.3)
* activesupport (4.2.3)
* acts-as-taggable-on (3.5.0)
* acts_as_commentable (4.0.2)
GIT
remote: git://github.com/ifad/data-confirm-modal.git
revision: 931cab3b269c6dab301245be2b2d738b243ba169
specs:
data-confirm-modal (1.0.2)
railties (>= 3.0)
GEM
remote: https://rubygems.org/
specs:
@rcanand
rcanand / links_gmail_and_safari.rb
Created February 14, 2011 22:07
Extracts and shows links from gmail and safari bookmarks
## /config/initializers/dynamic_job.rb
require 'heroku'
# base class for all jobs that you wish to automatically scale and go down in Heroku
class DynamicJob
#set a cap on maximum number of users ever - just in case.
MAX_CONCURRENT_WORKERS = 100
def initialize
# in config/initializers/devise.rb
if(ENV["RAILS_ENV"]== "development")
config.confirm_within = 15.days
else
config.confirm_within = 0
end