Category: javascript
Pre-requisites The Microbit project can be created in browser: https://makecode.microbit.org Alternatively, you could download the Microbit App from https://microbit.org/code/ The microbit is currently supported on Windows, Android and iOS. …
Given a binary tree and a sum, find all root-to-leaf paths where each path’s sum equals the given sum. Note: A leaf is a node with no children. Example: …
In Javascript, the arrays are passed by reference, and sometimes we want to clone an array. We cannot use the simple = operator as the reference is assigned. var …
A robot on an infinite grid starts at point (0, 0) and faces north. The robot can receive one of three possible types of commands: -2: turn left 90 …
In Javascript, the operator instanceof is used to perform a test to check if the prototype property of a constructor apperas in the chain of the object’s prototype chain. …