1. (TCO 8) Which words belong in the blank to indicate that the method PutFiles() returns a double value to the calling method, and that only the class containing PutFiles() is allowed to call it?_____ Put Files() 

private static double

public static double

private static void

public static void

 

2. (TCO 8) Which is a correct heading for a method that accepts three doubles and returns their sum? 

public static void Add(double num1, num2, num3);

public static Add(double num1, double num2, double num3);

public static double Add(double num1, double num2, double num3);

public static sum Add(double num1, double num2, double num3);

 

3. (TCO 8) Suppose your code has two variables declared as:

double myNumber = 2.17;

int myInt = 6;

Which of the following would be a legal call to this method:

public static double getWidgets(int num1, double num2) 

double getWidgets(myInt, myNumber);

getWidgets (myInt, myNumber);

myInt = getWidgets(myNumber);

double newWidget = getWidgets(myInt, myNumber);

 

4. (TCO 7) Which is a valid overloaded version of this method:

char CalculateGrade(double val1, double val2) 

char CalculateGrade(int val1)

char CalculateMyGrade(int val1, double val2)

char CalculateMyGrade(double val1)

double CalculateGrade(double val1, double val2) 

 

    • 12 years ago
    A+ Answers
    NOT RATED

    Purchase the answer to view it

    blurred-text
    • attachment
      11.doc