Escrito por estudiantes que aprobaron Inmediatamente disponible después del pago Leer en línea o como PDF ¿Documento equivocado? Cámbialo gratis 4,6 TrustPilot
logo-home
Document preview thumbnail
Vista previa 2 fuera de 7 páginas
Examen

Programming Logic and Design Chapter 9 Review AND Vocabulary Complete Answers

Document preview thumbnail
Vista previa 2 fuera de 7 páginas

Programming Logic and Design Chapter 9 Review AND Vocabulary Complete Answers

Vista previa del contenido

Programming Logic and Design
Chapter 9 Review AND Vocabulary
Complete Answers

7. When you use a variable name in a method call, it______________as the variable
in the method header.

a. can have the same name

b. cannot have the same name

c. must have the same name

d. cannot have the same data type - ANSWER-a. can have the same name

8. Assume that you have written a method with the header void myMethod(num a,
string b). Which of the following is a correct method call?

a. myMethod(12)

b. myMethod(12, "Hello")

c. myMethod("Goodbye")

d. It is impossible to tell. - ANSWER-b. myMethod(12, "Hello")

9. Assume that you have written a method with the header num yourMethod(string
name, num code). The method's type is__________.

a. num

b. string

c. num and string

d. void - ANSWER-a. num

10. Assume that you have written a method with the header string myMethod(num
score, string grade). Also assume that you have declared a numeric variable named
test. Which of the following is a correct method call?

a. myMethod()

b. myMethod(test)

, c. myMethod(test, test)

d. myMethod(test, "A") - ANSWER-d. myMethod(test, "A")

11. The value used in a method's return statement must__________.

a. be numeric

b. be variable

c. match the data type used before the method name in the header

d. two of the above - ANSWER-c. match the data type used before the method name
in the header

12. When a method receives a copy of the value stored in an argument used in the
method call, it means the variable was____________. b

a. unnamed

b. passed by value

c. passed by reference

d. assigned its original value when it was declared - ANSWER-b. passed by value

13. A void method_______________.

a. contains no statements

b. requires no parameters

c. returns nothing

d. has no name - ANSWER-c. returns nothing

14. When an array is passed to a method, it is____________.

a. passed by reference

b. passed by value

c. unnamed in the method

d. unalterable in the method - ANSWER-a. passed by reference

15. When you overload a method, you write multiple methods with the
same_________________.

a. name

Información del documento

Subido en
22 de marzo de 2025
Número de páginas
7
Escrito en
2024/2025
Tipo
Examen
Contiene
Preguntas y respuestas
$14.99

¿Documento equivocado? Cámbialo gratis Dentro de los 14 días posteriores a la compra y antes de descargarlo, puedes elegir otro documento. Puedes gastar el importe de nuevo.
Escrito por estudiantes que aprobaron
Inmediatamente disponible después del pago
Leer en línea o como PDF

Seller avatar
Los indicadores de reputación están sujetos a la cantidad de artículos vendidos por una tarifa y las reseñas que ha recibido por esos documentos. Hay tres niveles: Bronce, Plata y Oro. Cuanto mayor reputación, más podrás confiar en la calidad del trabajo del vendedor.
lectknancy
3.8
(80)
Vendido
327
Seguidores
27
Artículos
26139
Última venta
4 días hace



Por qué los estudiantes eligen Stuvia

Creado por compañeros estudiantes, verificado por reseñas

Calidad en la que puedes confiar: escrito por estudiantes que aprobaron y evaluado por otros que han usado estos resúmenes.

¿No estás satisfecho? Elige otro documento

¡No te preocupes! Puedes elegir directamente otro documento que se ajuste mejor a lo que buscas.

Paga como quieras, empieza a estudiar al instante

Sin suscripción, sin compromisos. Paga como estés acostumbrado con tarjeta de crédito y descarga tu documento PDF inmediatamente.

Student with book image

“Comprado, descargado y aprobado. Así de fácil puede ser.”

Alisha Student

Preguntas frecuentes