
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
AmitDiwan has Published 10744 Articles

AmitDiwan
1K+ Views
We are required to write a JavaScript function that takes in an array of numbers and returns the cumulative sum of every number present at the index that is a multiple of n from the array.ExampleThe code for this will be −const arr = [5, 3, 5, 6, 12, 5, ... Read More

AmitDiwan
205 Views
We are required to write a JavaScript function that takes in an array of Number. Then the function should return the average of its elements excluding the smallest and largest Number.ExampleThe code for this will be −const arr = [5, 3, 5, 6, 12, 5, 65, 3, 2]; const findExcludedAverage ... Read More

AmitDiwan
180 Views
We are required to write a JavaScript function that takes in two arrays of literals. The function should check the corresponding elements of the array. The function should return true if all the corresponding elements of the array are equal otherwise it should return false.ExampleThe code for this will be ... Read More

AmitDiwan
360 Views
We are required to write a JavaScript function that takes in a string and a number n (such that n exactly divides the length of string) and we need to return an array of string of length n containing n equal parts of the string.ExampleThe code for this will be ... Read More

AmitDiwan
687 Views
We are required to write a JavaScript function that takes in a string and returns the character from the string that appears for the second most number of times.ExampleThe code for this will be −const arr = [5, 2, 6, 7, 54, 3, 2, 2, 5, 6, 7, 5, 3, ... Read More

AmitDiwan
251 Views
We are required to write a JavaScript function that takes in an array of nested arrays of Numbers and some falsy values (including 0) and some strings as well and the function should return the product of number values present in the nested array. If the array contains some 0s, ... Read More

AmitDiwan
229 Views
We are required to write a JavaScript function that takes in two strings and returns the count of the number of times the str1 appears in the str2.ExampleThe code for this will be −const main = 'This is the is main is string'; const sub = 'is'; const countAppearances = ... Read More

AmitDiwan
116 Views
We are required to write a JavaScript function that takes in Number arrays and returns the element from arrays that are not common to both.For example, if the two arrays are −const arr1 = [2, 4, 2, 4, 6, 4, 3]; const arr2 = [4, 2, 5, 12, 4, 1, ... Read More

AmitDiwan
143 Views
We are required to write a JavaScript function that takes in a number and returns true if it is a Pronic number otherwise returns false.A Pronic number is a number which is the product of two consecutive integers, that is, a number of the form −n(n + 1)ExampleThe code for ... Read More

AmitDiwan
61 Views
We are required to write a JavaScript function that takes in an array of positive as well as negative Numbers and changes the positive numbers to corresponding negative numbers and the negative numbers to corresponding positive numbers in place.ExampleThe code for this will be −const arr = [12, 5, 3, ... Read More