Coin - d @name = coinName @value = coinValue end e def...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#Coded by srihari jagan vasista #Includes methods like getvalue,getName for the coin class class Coin #attr_accessor :name, :value @name = "" @value = 0 @ def initialize(coinName = "penny",coinValue = 1)
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: d @name = coinName @value = coinValue end e def getValue() return @value end e def getName() return @name end e end...
View Full Document

This document was uploaded on 05/04/2011.

Ask a homework question - tutors are online