1. What is Closure ? Junior A. the way a block grabs and retains outside constants and variables it references B. a self-contained block of code that can be passed around and captures references from its surrounding scope C. the default for a block guaranteed to run before the enclosing function returns, allowing optimizations D. syntax that moves a function's final block argument outside the parentheses for readability Answer + AI explanation with Pro
2. Which term means: "a self-contained block of code that can be passed around and captures references from its surrounding scope"? Junior A. Trailing closure B. Variable capture C. non-escaping D. Closure Answer + AI explanation with Pro
3. Which statement is correct? Junior A. Closure — an attribute marking a block that may be stored and called after the function it was passed to returns B. Closure — a self-contained block of code that can be passed around and captures references from its surrounding scope C. Closure — syntax that moves a function's final block argument outside the parentheses for readability D. Closure — the way a block grabs and retains outside constants and variables it references Answer + AI explanation with Pro
4. What is Trailing closure ? Mid A. a self-contained block of code that can be passed around and captures references from its surrounding scope B. the default for a block guaranteed to run before the enclosing function returns, allowing optimizations C. syntax that moves a function's final block argument outside the parentheses for readability D. an attribute marking a block that may be stored and called after the function it was passed to returns Answer + AI explanation with Pro
5. Which term means: "syntax that moves a function's final block argument outside the parentheses for readability"? Mid A. escaping B. non-escaping C. Trailing closure D. Closure Answer + AI explanation with Pro
6. Which statement is correct? Mid A. Trailing closure — an attribute marking a block that may be stored and called after the function it was passed to returns B. Trailing closure — the default for a block guaranteed to run before the enclosing function returns, allowing optimizations C. Trailing closure — syntax that moves a function's final block argument outside the parentheses for readability D. Trailing closure — a self-contained block of code that can be passed around and captures references from its surrounding scope Answer + AI explanation with Pro
7. What is escaping ? Senior A. syntax that moves a function's final block argument outside the parentheses for readability B. the way a block grabs and retains outside constants and variables it references C. an attribute marking a block that may be stored and called after the function it was passed to returns D. the default for a block guaranteed to run before the enclosing function returns, allowing optimizations Answer + AI explanation with Pro
8. Which term means: "an attribute marking a block that may be stored and called after the function it was passed to returns"? Senior A. escaping B. Closure C. Trailing closure D. non-escaping Answer + AI explanation with Pro
9. Which statement is correct? Senior A. escaping — an attribute marking a block that may be stored and called after the function it was passed to returns B. escaping — the way a block grabs and retains outside constants and variables it references C. escaping — the default for a block guaranteed to run before the enclosing function returns, allowing optimizations D. escaping — a self-contained block of code that can be passed around and captures references from its surrounding scope Answer + AI explanation with Pro
10. What is non-escaping ? Senior A. a self-contained block of code that can be passed around and captures references from its surrounding scope B. the default for a block guaranteed to run before the enclosing function returns, allowing optimizations C. syntax that moves a function's final block argument outside the parentheses for readability D. the way a block grabs and retains outside constants and variables it references Answer + AI explanation with Pro
11. Which term means: "the default for a block guaranteed to run before the enclosing function returns, allowing optimizations"? Senior A. non-escaping B. Closure C. Variable capture D. escaping Answer + AI explanation with Pro
12. Which statement is correct? Senior A. non-escaping — syntax that moves a function's final block argument outside the parentheses for readability B. non-escaping — the way a block grabs and retains outside constants and variables it references C. non-escaping — an attribute marking a block that may be stored and called after the function it was passed to returns D. non-escaping — the default for a block guaranteed to run before the enclosing function returns, allowing optimizations Answer + AI explanation with Pro
13. What is Variable capture ? Mid A. the default for a block guaranteed to run before the enclosing function returns, allowing optimizations B. the way a block grabs and retains outside constants and variables it references C. syntax that moves a function's final block argument outside the parentheses for readability D. an attribute marking a block that may be stored and called after the function it was passed to returns Answer + AI explanation with Pro
14. Which term means: "the way a block grabs and retains outside constants and variables it references"? Mid A. Trailing closure B. Closure C. escaping D. Variable capture Answer + AI explanation with Pro
15. Which statement is correct? Mid A. Variable capture — the default for a block guaranteed to run before the enclosing function returns, allowing optimizations B. Variable capture — the way a block grabs and retains outside constants and variables it references C. Variable capture — syntax that moves a function's final block argument outside the parentheses for readability D. Variable capture — a self-contained block of code that can be passed around and captures references from its surrounding scope Answer + AI explanation with Pro