
JavaScriptAvanzado-II
Authored by Viviana Cruz
Fun, Education
1st - 12th Grade
Used 10+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
8 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿Qué es un CLOSURE?
una funcion que retorna otra funcion
una funcion que retorna otra funcion y que usa una variable definida en el scope de la funcion que la retornó
una variable que dentro del scope de una funcion retornada por otra funcion
es un mito de JavaScript
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿En qué momento pasa una función que está en el event queue al execution stack?
cuando pasa una determinada cantidad de tiempo.
cuando el execution stack esta vacio.
no se puede predecir el momento.
cuando el servicio ecterno termina de ejecutar el callback.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿En qué orden van a salir los outputs?
setTimeOut(function() {
console.log('uno');
}, 1000);
setTimeOut(function() {
console.log('dos');
}, 1500);
setTimeOut(function() {
console.log('tres');
}, 0);
console.log('cuatro');
cuatro uno dos tres
uno dos tres cuatro
tres dos uno cuatro
cuatro tres uno dos
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
La diferencia entre 'call' y 'bind' es que:
Bind retorna una nueva funcion, call invoca la funcion
Call cambia el valor del this, y bind no
no hay diferencia
los argumentos que reciben
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
En JavaScript podemos controlar el valor del keyword this de manera arbitraria.
Verdadero
Falso
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
En el código siguiente, qué variable quedaría en un CLOSURE al invocar `makeAdder`?
function makeAdder(x) {
return function(y) {
return x + y;
}
}
var add5 = makeAdder(5);
var add10 = makeAdder(10);
y
no hay closure
x
x e y
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
La diferencia entre `call` y `apply` es:
los parametros que reciben
una retorna una funcion nueva y otraa la invoca
la forma en que cambian el this
no hay ninguna diferencia
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Microsoft
or continue with
%20(1).png)
Apple
Others
Already have an account?