Skip to content

Instantly share code, notes, and snippets.

@jordanhudgens
Last active July 11, 2016 15:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jordanhudgens/d0b9b172f4fd4c650f605ca6644bb375 to your computer and use it in GitHub Desktop.
Save jordanhudgens/d0b9b172f4fd4c650f605ca6644bb375 to your computer and use it in GitHub Desktop.
class Invoice
def initialize(customer, total)
@customer = customer
@total = total
end
def summary
puts "Invoice:"
puts "Customer: #{@customer}"
puts "Total: #{@total}"
end
end
invoice = Invoice.new("Company ABC", 500)
invoice.summary
# Invoice:
# Customer: Company ABC
# Total: 500
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment