Category: Intermediate

0

Determine if a binary tree is balanced

A balanced tree is defined to be a tree such that the heights of the two subtrees of any node never differ more than one. Input : The root of a binary tree Output...

0

Transform json to json

Problem description : Write a function which transforms the given JSON as shown belows : Input : Given an endorsment array with objects containing skill and user keys var endorsements = [ { skill:...

0

Filter and sort the given array

Problem description : Write a function that filters the invalid entries from the given array by removing the following elements : which does not have either id or extension property whose id value is...

0

Random Dice Roll Challenge

Problem description : Write a javascript function that accepts a string argument in the format {digit}d{digit}; where The first digit represents the number of dices. The second digit represents the number of sides. The...