Math, asked by soniya4818, 1 year ago

how to make functions in java?

Answers

Answered by sami91
3
Hey there !

You can see three keywords public , static and void before the function name. The public keyword makes myMethod() method public . The static keyword denotes that the method can be accessed without creating the object of the class. The void keyword signifies that the method doesn't return any value.

Hope it helps you !
Similar questions