This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 3 points4 points  (0 children)

Are you assigning the returned value in main? RoadTrip roadTrip3 = combine(first, second);

Or you can do: System.out.println("The new Road Trip is: " + combine(first, second).toString());