public class C extends B
Modifier and Type | Field and Description |
---|---|
(package private) double |
z |
Constructor and Description |
---|
C(double x,
double y,
double z)
Initializes and newly created C object.
|
Modifier and Type | Method and Description |
---|---|
double |
power()
The product of the attributes.
|
double |
product()
The product of the attributes.
|
double |
sum()
The sum of the attributes.
|
java.lang.String |
toString()
toString method for the C class.
|
public C(double x, double y, double z)
x
- the value for xy
- the value for yz
- the value for zpublic double sum()
public double product()
public double power()
Math.pow(double, double)