// Method: CalculateNet
// Parameters
// grossP: double storing the grossPay
// tax: double storing tax percentage to be removed from gross pay
// netP: call by reference double storing the computed net pay
// Returns: void
public static void CalculateNet(double grossP, double tax, ref double netP)
{
// *** Insert the details of the CalculateNet Method
}
Question is to Insert the details of the CalculateNet Method
// Method: CalculateNet
// Parameters
// grossP: double storing the grossPay
// tax: double storing tax percentage to be removed from gross pay
// netP: call by reference double storing the computed net pay
// Returns: void
public static void CalculateNet(double grossP, double tax, ref double netP)
{
// *** Insert the details of the CalculateNet Method
netP = grossP - (grossP*tax/100.0);
}
Comments
Leave a comment