Why use method?


#1

I just finished the Dog class project and I am a bit confused of why we are using methods just to print those three lines. Why couldn’t we just println? Why use methods? If anyone can give an example on how they are useful that would be awesome!

Thanks!


#2

The reason behind using methods is to show how they works in Java. It is crucial to understand how the can be built and how they work.


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.