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 5 páginas
Examen

IB Computer Science OOP Practice Exam Questions And Answers Rated A+.

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

What is the difference between an object and a class? - Answer an object is an instance of a class what is class decomposition? - Answer breaking a programming problem into multiple classes where each class has a specific task to perform in solving the problem. what are two characteristics of an object? - Answer - state (Variables) - behaviour (Methods) what does it mean to instantiate an object? - Answer using a class's constructor to create an instance of an object. in Java you use the keyword new. example: Student student = new Student("John", "Wayne"); what is a primitive data type and what are the 8 different ones? - Answer A value that is predefined by the language and is named to a reserved keyword - byte : 8 bit signed number variable - short : 16 bit signed number variable - int : 32 bit signed number variable - long : 64 bit signed number variable - float : 32 bit decimal value - double : 64 bit decimal value - boolean : true or false - char : single character

Vista previa del contenido

IB Computer Science OOP Practice
Exam Questions And Answers Rated A+.
What is the difference between an object and a class? - Answer an object is an instance of a class



what is class decomposition? - Answer breaking a programming problem into multiple classes where
each class has a specific task to perform in solving the problem.



what are two characteristics of an object? - Answer - state (Variables)

- behaviour (Methods)



what does it mean to instantiate an object? - Answer using a class's constructor to create an instance
of an object.

in Java you use the keyword new.

example:

Student student = new Student("John", "Wayne");



what is a primitive data type and what are the 8 different ones? - Answer A value that is predefined by
the language and is named to a reserved keyword



- byte : 8 bit signed number variable

- short : 16 bit signed number variable

- int : 32 bit signed number variable

- long : 64 bit signed number variable

- float : 32 bit decimal value

- double : 64 bit decimal value

- boolean : true or false

- char : single character

, what is a parameter and what are the two types? - Answer a value that is passed to a method for it to
use.

formal and actual parameters



what is a formal parameter? - Answer parameters in the header of the method declaration are called
formal parameters and they are limited to the method they are declared in



what is an actual parameter? - Answer values passed into a method are called actual parameters or
arguments



what are advantages of object libraries? - Answer - code reusability

- complex algorithms do not need re-invention

- efficiency



what are disadvantages of OOP? - Answer - overly complex for simple problems

- tendency of over abstraction



what is aggregation? - Answer "has a" relationship between two classes where an object of one class
has an object of another.



example:

public class Classroom

{private Teacher teacher; // Classroom has a Teacher}



what are the advantages of modularity in program development? - Answer - productivity

- usability

- easily maintained

- code reusability



why should to dependencies between objects be reduced? - Answer because they decrease reusability

Información del documento

Subido en
31 de enero de 2025
Número de páginas
5
Escrito en
2024/2025
Tipo
Examen
Contiene
Preguntas y respuestas
$10.59

¿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.
COCOSOLUTIONS
4.2
(37)
Vendido
219
Seguidores
16
Artículos
9233
Última venta
1 semana 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