Skip to content

Latest commit

 

History

History
25 lines (12 loc) · 738 Bytes

18.md

File metadata and controls

25 lines (12 loc) · 738 Bytes

Define functions and call them

See video on udemy.

Notice

Functions' name needs to represent the task it's performing.

Notice

public means the function can be publicly accessed from any package or subfolder,

but because we've got only one package with a single class in it,

it doesn't really matter what level of access you specify.

Notice

You can notice that main() is also a function, it has a very similar signature to our functions.

Every function has a specific task that it performs, the main() function performs the task of running our application.

The main() function has a very specific signature that the JVM looks for when you run your app, when it finds main() function, it executes it.