Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View mPanasiewicz's full-sized avatar

Maciej Panasiewicz mPanasiewicz

View GitHub Profile
times in msec
clock self+sourced self: sourced script
clock elapsed: other lines
000.008 000.008: --- VIM STARTING ---
000.093 000.085: Allocated generic buffers
000.725 000.632: locale set
000.761 000.036: GUI prepared
puts "Please enter cost"
cost = gets.chomp.to_f
puts "Please enter money"
money = gets.chomp.to_f
rest = money - cost
if rest < 0
puts "You still owe %.2f" % rest
tw = te = f = o = q = d = n = p = 0,0,0,0,0,0,0,0
puts "Please enter cost"
cost = gets.chomp.to_f
puts "Please enter money"
money = gets.chomp.to_f
rest = money - cost
while rest < 0
puts "You still owe %.2f" % rest
tw,te,f,o,q,d,n,p = 0,0,0,0,0,0,0,0
class AddRequestFieldToCasheNames < ActiveRecord::Migration
class CacheName < ActiveRecord::Base
end
def change
add_column :cache_names, :request, :text
CacheName.find_each do |cache_name|
cache_name.request = '{"method":"get_config","type":"kom","channel":"direct","sign":"587d6320f50666918c40c4bf125164b8","transform_ver":"' + cache_name.transform_ver + '","pkb_content_ver":"A1"}'
cache_name.save
end