Tip 1: Strengthen Your DSA Foundations
Tip 2: Sharpen Your Problem-Solving Skills
Tip 1: Maintain Honesty and Clarity.
Tip 2: Work on Real, Practical Projects.


You are given ‘MARKS’ = [7, 10, 9, 5], Here you can distribute candies as [1, 3, 2, 1]. Here all the students with higher marks than the students sitting beside them also have more candies. Hence the answer is 7.
What is the difference between == and === in JavaScript? (Learn)
How to create a table in HTML? (Learn)



Input: 'n' = 5, 'arr' = [1, 2, 3, 4, 5]
Output: 5
Explanation: From the array {1, 2, 3, 4, 5}, the largest element is 5.

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
What is the purpose of the return keyword?