SJSU/Udacity CS046

Lesson 2 - Objects

  1. Introduction
  2. Introducing Ellora
  3. Why OOP is Important
  4. Objects
  5. Objects Demo
  6. Quiz: Mariner 4
  7. Classes
  8. Quiz: Match the Methods
  9. Drawing Pictures
  10. Quiz: What Does This Method Do?
  11. Variables
  12. Variable Names
  13. Quiz: An Exercise on Variable Names
  14. Variable Types
  15. Quiz: Variable Types
  16. Initial Values
  17. Quiz: Initial Values
  18. Comments
  19. Quiz: How Many Days
  20. Quiz: Adding Comments
  21. Quiz: Variable Declarations: The Fine Print
  22. Variable Values Can Change
  23. Public Interfaces
  24. Public Interfaces 2
  25. Arguments and Return Values
  26. Quiz: Arguments and Return Values Exercise
  27. Method Declarations
  28. Quiz: Method Description
  29. Quiz: More Method Descriptions
  30. Constructing Objects
  31. Making Rectangles
  32. Quiz: Constructing Rectangles
  33. String Methods
  34. Quiz: The replace Method
  35. Quiz: The trim Method
  36. Quiz: toUpperCase and toLowerCase
  37. Accessors and Mutators
  38. Quiz: Accessor or Mutator?
  39. Quiz: Accessor or Mutator? 2
  40. Quiz: Pitfall
  41. Shared Objects
  42. Quiz: Copying Rectangles
  43. Quiz: Copying Strings
  44. Quiz: Copying Numbers
  45. Implementing a Test Program
  46. Quiz: Test Program
  47. Why It's Important to Test Your Code
  48. More About Graphics
  49. Quiz: Draw a Crate
  50. Quiz: Write Top Secret
  51. Quiz: Intro to Color
  52. Colors
  53. Matching Color
  54. An Interesting Project Ellora Worked On
  55. Ellora's Advice to You
  56. Conclusion

Quiz: How Many Days

You should use the days2 BlueJ project.

When you are done, press Start and type in your answer below.

Astronaut Sally Ride was born on May 26th, 1951 and died on July 23, 2012. What is the number of days that she lived? 22339 Run the days2 BlueJ project. Make two Day variables and use the daysFrom method. Check out the answer video if you aren't sure how.

Problem on this page?

Your name:

Your email address:

Problem description:

To protect against spam robots, please answer this simple math problem:
× =