I haven't initialized anything on main. All I want is to call an outside method. However, when calling on picnicCost(), I don't know what to put inside the parenthesis since I didn't use any variables in main.
import java.util.*;
public class picnic
{
static Scanner scan=new Scanner(System.in);
public static void main(String args[])
{
picnicCost(0,0,0);
}
public static double flatFee(double a)
{
System.out.println("Enter the number of people attending: ");
a=scan.nextDouble();
return a*5.00;
}
public static double MealP(double b)
{
System.out.println("Enter the number of poeple purchasing a meal: ");
b=scan.nextDouble();
return b*2.75;
}
public static double iceCreamCost(double c)
{
System.out.println("Enter the number of poeple purchasing ice cream: ");
c=scan.nextDouble();
return c*.75;
}
public static double picnicCost(double a, double b, double c)
{
return flatFee(a) + MealP(b) + iceCreamCost(c);
}
}