View autoexec.cfg
// autoexec.cfg | |
// ============ | |
// = Bindings = | |
// ============ | |
bind "kp_end" "buy ak47; buy m4a1;" | |
bind "kp_downarrow" "buy galilar; buy famas;" | |
bind "kp_pgdn" "buy awp;" | |
bind "kp_leftarrow" "buy bizon;" |
View cards.rb
# TODO: Create InvalidCard, DuplicateCard & InvalidDeck exceptions | |
class Card | |
# 11 - 14 represent Jack through Ace respectively | |
VALUES = (2..14).to_a | |
SUITS = [:spades, :clubs, :hearts, :diamonds] | |
attr_reader :value, :suit | |
def initialize value, suit |
View ruby_monk_primer.rb
# Problem Statement | |
# Create a class Calculator, which performs addition and subtraction of two numbers at a time. | |
class Calculator | |
def add(a, b) | |
a+b | |
end | |
def subtract(a, b) | |
a-b | |
end |