public class BillTest
{
public static void main (String[]arg)
{
Bill mum=new Bill(130,100);
Bill sister=new Bill(200,50);
Bill family=new Bill(0,0);
family=family.calculateTotal(mum,sister);
System.out.println("Total bill:");
family.calculateBill();
}
}What calculate method can be use to calculate of 2 object mum&sister in family object....public class Bill
{
int airtime;
int totalSms;
int total;
public double callrate=0.25;
public double smsrate=0.05;
Bill(int a, int s)
{
airtime = a;
totalSms= s;
}
public double calculateBill()
{
return (airtime * callrate+ totalSms * smsrate);
}
public double calculateTotal(int m, int s)
{
double total= m + s;
return(total);
}
}
confusing... Some buddy help me?