R1: Question 1
Given the below code. Write a function (ES6 recommended) that loops through all the properties of the Employee and create a comma-seperated string with the values
{
firstName: "X",
lastName: "Y",
project: {
id: 1,
name: "ABC"
}
}
should be converted to a string like this "X, Y, 1, ABC, "Write a function here called 'convertToString' that will return the expected result.
The function shouldn't convert the prototypically inherited properties
R1: Question 2
Given a list of student test scores, find the best average grade. Each student may have more than one test score in the list.
Complete the bestAverageGrade function in the editor below. It has one parameter, scores, which is an array of student test scores. Each element in the array is a two-element array of the form [student name, test score] e.g. [ "Bobby", "87" ].
Test scores may be positive or negative integers.
If you end up with an average grade that is not an integer, you should use a floor function to return the largest integer less than or equal to the average. Return 0 for an empty input.
Example:
Input:
[ [ "Bobby", "87" ],
[ "Charles", "100" ],
[ "Eric", "64" ],
[ "Charles", "22" ] ].
Expected output: 87R2: Question 3
https://leetcode.com/problems/split-a-string-in-balanced-strings/
R3: Question 4
https://leetcode.com/problems/combination-sum/
R3: Question 5
[This is a frontend specific question]
Write a React component for Typeahead
Hope this helps!