Task 8 of 9 · 0 solved · 9 to go0%
You can read the problem, but answers are checked only for signed-in students. Sign in to answer →

4.5 Static and toString — same dog?

Total: 0 / 3 pts
Practice mode — check each part and get hints as you go.
Task

Fill in sameName so that it returns whether two dogs carry the same name.

The program prints false and then true: the two dogs are different objects (so == is false), but their names match.

Your solution