• ¿Documento equivocado? Cámbialo gratis
  • Escrito por estudiantes que aprobaron
  • Inmediatamente disponible después del pago
  • Leer en línea o como PDF
Vender
¿Dónde estudias?
Tu idioma
Document preview thumbnail
Vista previa 1 fuera de 4 páginas
Examen

2110 Final Exam(with Errorless answers)

Document preview thumbnail
Vista previa 1 fuera de 4 páginas

Thread correct answers program unit executed independently of other parts of the program What do you need to create a thread correct answers Runnable interface and a class that implements the runnable interface How does a thread ends correct answers it ends when the run() method terminates (returns) rupt() - returns boolean value correct answers NOTIFIES that thread should end (does not end thread itself , sleep() correct answers watches and checks for interrupted exception thread scheduler correct answers runs each thread for a short amount of time race condition correct answers the effect of multiple threads on shared data depends on the order in which the threads are scheduled. lock object correct answers used to control threads that manipulate shared resources 3 steps to use lock correct answers 1. create lock alize lock 3. lock then unlock deadlock correct answers when one thread holds back indefinitely and others cannot acquire lock condition object correct answers will not release object till condition is met .await() correct answers calling thread will wait until signaled .signalAll() correct answers unblocks all threads waiting on condition 3 parts of recursion correct answers base case, recursive case, case that leads to the base case When is recursion not a good idea ? correct answers repeated sub problems (fibonacci) bottom up approach that remembers small solutions better What are the 3 examples of types of basic recursive code correct answers Binary Search, Divide and conquer, merge-sort linked lists correct answers uses reference pointers between list nodes (elements) to maintain order tree correct answers hierarchical data structure in which each element has only one predecessor and zero one, or more successors

Vista previa del contenido

2110 Final Exam(with Errorless answers)
Thread correct answers program unit executed independently of other parts of the program

What do you need to create a thread correct answers Runnable interface and a class that
implements the runnable interface

How does a thread ends correct answers it ends when the run() method terminates (returns)

t.interrupt() - returns boolean value correct answers NOTIFIES that thread should end (does not
end thread itself ,

sleep() correct answers watches and checks for interrupted exception

thread scheduler correct answers runs each thread for a short amount of time

race condition correct answers the effect of multiple threads on shared data
depends on the order in which the threads are scheduled.

lock object correct answers used to control threads that manipulate shared resources

3 steps to use lock correct answers 1. create lock
2.initialize lock
3. lock then unlock

deadlock correct answers when one thread holds back indefinitely and others cannot acquire lock

condition object correct answers will not release object till condition is met

.await() correct answers calling thread will wait until signaled

.signalAll() correct answers unblocks all threads waiting on condition

3 parts of recursion correct answers base case, recursive case, case that leads to the base case

When is recursion not a good idea ? correct answers repeated sub problems (fibonacci)
bottom up approach that remembers small solutions better

What are the 3 examples of types of basic recursive code correct answers Binary Search, Divide
and conquer, merge-sort

linked lists correct answers uses reference pointers between list nodes (elements) to maintain
order

tree correct answers hierarchical data structure in which each element has only one predecessor
and zero one, or more successors

Información del documento

Subido en
30 de abril de 2025
Número de páginas
4
Escrito en
2024/2025
Tipo
Examen
Contiene
Preguntas y respuestas
$11.39

¿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.
Vendido
23
Seguidores
6
Artículos
4026
Última venta
2 meses 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