-
Notifications
You must be signed in to change notification settings - Fork 43
Carets -- CanaanWest resubmit #46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Solar SystemWhat We're Looking For
|
| end | ||
|
|
||
| def user_compare_planets(solarsystem, planet1, planet2) | ||
| planet1_position = solarsystem.find_planet(planet1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
very small observation: your code doesn't check if the input name is a valid choice before you call solarsystem.find_planet :P
|
Good code! You show a great understanding of how to pass objects/values as arguments to other methods, and using those arguments. The code is well done. Regarding your answers to the comprehension questions: Your solar system does not take in an array of hashes, it (appropriately) takes in an array of By the way, using the shortcut to align indentations in code is exactly what it's meant to be used for! :) |
| @@ -0,0 +1,198 @@ | |||
| #PLANETS | |||
| class Planets | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
small note: You may want to rename your classes so that they are always singular, as they represent a single Planet in this case.
| puts planet_rotational_age(canaansworld, canaansworld.age, planet_choice) | ||
|
|
||
| elsif answer == "exit" | ||
| puts "Well, ttyl then, nerd" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💥
Solar System
Congratulations! You're submitting your assignment.
Comprehension Questions
initializemethod in your class?SolarSystemused anArrayvs aHash.