What are classes and what are objects?
A Week 5 Reflection
May 10, 2015
Outline: Classes allow us to create basic templates. + For example create a "child" class. It could have variables like "eat" "sleep" "play". And it also would have instance variables like @gender, @age, @sport, @race. + Help promotes consistence across the class. Introduction to "Madison" class Athlete def initialize (name, gender, age, sport, event) @name = name @gender = gender @age = age @sport = sport @event = event end end Lilly = athelete.new("Lilly", female", "12", "track and field", "400 meters") Sunil = athlete.net("Sunil", male", "15", "track and field", "long jump") class Athlete def athlete_profile puts "#{@Name} is a #{@gender} athelete, age #{@age}, and is part of the #{sport} team and will participate in the #{@event} event. Instance is LIlly and Sunil. How to identify?