Functions in Java
Functions in Java
BANI PARK
Computer Application
CLASS 10 sc/comm.
Functions in java
A function is a piece of code that is called by name.
It can be passed data to operate on (i.e. the
parameters) and can optionally return data (the
return value). All data that is passed to a function is
explicitly passed.
ACCESS SPECIFIERS
Java Access Specifiers/Modifiers (also
known as Visibility Specifiers )
regulate access to classes, fields and
methods in Java.
These Specifiers determine whether a field
or method in a class, can be used or
invoked by another method in another class
or sub-class.
There are four access
specifiers/modifiers in java: