Free JS-Dev-101 sample questions
Real questions from the Salesforce Certified JavaScript Developer I practice bank, with the correct answer and an explanation for each one. No junk, no filler.
Try them in the simulator Same questions, with study, timed and flashcard modes.
Showing 8 of 17 free sample questions.
Consider the following code snippet involving object mutation: ```javascript const config = { env: 'dev', retries: 3 }; config.retries = 5; config = { env: 'prod', retries: 1 }; ``` What happens when this code executes?
A developer needs to sort an array of product objects by price (ascending). The price is a numeric property. `const products = [{id: 1, price: 100}, {id: 2, price: 5}, {id: 3, price: 25}];` Which sort implementation works correctly?
A developer is parsing a JSON string received from an API. The string contains a date field in ISO format. The developer wants to automatically convert this string into a JavaScript Date object during parsing. Which feature of `JSON.parse` should be used?
Which of the following expressions evaluates to `true` in JavaScript? (Select TWO)
A developer writes the following function to create a greeting: ```javascript function greet(name, greeting = 'Hello') { return `${greeting}, ${name}!`; } ``` What feature is being used for the `greeting` argument?
A financial application calculates tax using the following code: ```javascript let price = 100.50; let taxRate = 0.08; let total = price * taxRate; console.log(total); ``` The output is `8.040000000000001` instead of `8.04`. What is the primary cause of this behavior?
You are implementing a cache mechanism where keys must be objects (e.g., DOM elements) and you do not want to prevent garbage collection of these keys if they are removed from the DOM. Which data structure is most appropriate?
9 more free samples are waiting
Create a free account to unlock the whole JS-Dev-101 sample bank, or get full access to all 204 practice questions in the simulator.