Login
Remember
Register
User DavidAnderson
Wall
Recent activity
All questions
All answers
Ask a Question
Answers by DavidAnderson
0
votes
What is the output? const myLifeSummedUp = ['☕', '', '', '']; for (let item in myLifeSummedUp) { console.log(item); }
answered
Mar 11, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What is the output? const add = () => { const cache = {}; return num => {
answered
Mar 11, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
Is this a pure function? function sum(a, b) { return a + b; } A: Yes B: No
answered
Mar 11, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? const { firstName: myName } = { firstName: 'Lydia' }; console.log(firstName);
answered
Mar 11, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? const box = { x: 10, y: 20 }; Object.freeze(box); const shape = box; shape.x = 100;
answered
Mar 11, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? function addToList(item, list) { return list.push(item); }
answered
Mar 11, 2024
in
JavaScript
javacsript-interview-questions-answers
0
votes
What's the output? async function getData() { return await Promise.resolve('I made it!'); }
answered
Mar 11, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? console.log(String.raw`Hello\nworld`);
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
How can we log the values that are commented out after the console.log statement? function* startGame() {
answered
Mar 10, 2024
javascript-interview-questions-answers
0
votes
What's the output? console.log('' + '');
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? const name = 'Lydia Hallie'; console.log(name.padStart(13)); console.log(name.padStart(2));
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? console.log(Number(2) === Number(2)); console.log(Boolean(false) === Boolean(false));
answered
Mar 10, 2024
javascript-interview-questions-answers
0
votes
What's the output? // index.js console.log('running index.js'); import { sum } from './sum.js'; console.log(sum(1, 2));
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
With which constructor can we successfully extend the Dog class? class Dog { constructor(name)
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? [1, 2, 3, 4].reduce((x, y) => console.log(x, y));
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
const value = { number: 10 }; const multiply = (x = { ...value }) => { console.log((x.number *= 2)); };
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? let num = 10; const increaseNumber = () => num++; const increasePassedNumber = number => number++;
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? const settings = { username: 'lydiahallie', level: 19, health: 90, };
answered
Mar 10, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? const person = { name: 'Lydia' }; Object.defineProperty(person, 'age', { value: 21 });
answered
Mar 9, 2024
in
JavaScript
javascript-interview-questions-answers
0
votes
What's the output? const user = { name: 'Lydia', age: 21 }; const admin = { admin: true, ...user }; console.log(admin);
answered
Mar 9, 2024
in
JavaScript
javascript-interview-questions-answers
Page:
« prev
1
...
49
50
51
52
53
54
55
56
57
58
59
...
183
next »
...