
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
390 Views
Radix Sort Radix sort is a sorting algorithm that sorts data with integer keys by grouping keys by the individual digits which share the same significant position and value.We are required to write a JavaScript function that takes in an array of literals as the only argument. The function should sort ... Read More

AmitDiwan
676 Views
Caesar Cipher AlgorithmThe Caesar Cipher algorithm is one of the simplest and most widely known encryption techniques. It is a type of substitution cipher in which each letter in the plaintext is replaced by a letter some fixed number of positions down the alphabet.For exampleWith a left shift of 3, ... Read More

AmitDiwan
240 Views
Suppose we have an array of m * n order. A person starts at the start block of the 2-D array (0, 0) and he wants to reach the end (m, n). The limitation is that at once, he can either move one step down or one step right.We are ... Read More

AmitDiwan
576 Views
We are required to write a JavaScript function that takes in an array of arrays of n * n order (square matrix). The function should rotate the array by 90 degrees (clockwise). The condition is that we have to do this in place (without allocating any extra array).For example −If ... Read More

AmitDiwan
683 Views
Interpolation SearchInterpolation search is an algorithm for searching for a key in an array that has been ordered by numerical values assigned to the keys (key values).For exampleSuppose, we have a sorted array of n uniformly distributed values arr[], and we need to write a function to search for a ... Read More

AmitDiwan
9K+ Views
Levenshtein DistanceThe Levenshtein distance is a string metric for measuring the difference between two sequences. It is the minimum number of single-character edits required to change one word into the other.For example −Consider, we have these two strings −const str1 = 'hitting'; const str2 = 'kitten';The Levenshtein distance between these ... Read More

AmitDiwan
780 Views
The power set of a set S is the set of all of the subsets of S, including the empty set and S itself. The power set of set S is denoted as P(S).For exampleIf S = {x, y, z}, the subsets are −{ {}, {x}, {y}, ... Read More

AmitDiwan
494 Views
RadianThe radian is the unit for measuring angles and is the standard unit of angular measure used in many areas of mathematics.We are required to write a JavaScript function that takes in a number that represents some degree and returns its corresponding radian.ExampleFollowing is the code −const deg = 180; ... Read More

AmitDiwan
672 Views
Suppose we have the following problem −There are n stairs, a person standing at the bottom wants to reach the top. The person can climb either 1 or 2 stairs at a time. We are required to count the number of ways, the person can reach the top.We are required ... Read More

AmitDiwan
289 Views
Block SearchJust like Binary Search, Block Search is also a searching algorithm for sorted arrays. The basic idea is to check fewer elements (than linear search) by jumping ahead by fixed steps or skipping some elements in place of searching all elements.For exampleSuppose we have an array arr of length ... Read More