Learn how to stop forEach method in JavaScript. forEach is used to iterate through array items. This post will show you how to stop this method in between.
ReadJavaScript program to get the selected value from a dropdown list of items. We will create one HTML file that will show one dropdown to the user and using JavaScript, it will get the selected value.
ReadLearn to print a multiplication table in HTML, CSS and JavaScript. We will read the number as input from the user and it will print the multiplication table on a button click.
ReadJavaScript program to calculate age from date of birth of a person. We will learn two different ways to calculate the age from birth date.
ReadLearn how to add two numbers in javascript. We will learn three different ways to add two numbers in javascript. We will learn to add two numbers using HTML and by taking user inputs.
ReadJavaScript program to remove the last n characters from a string. We will learn two different ways to solve this. We will solve it by using slice() and substring().
ReadJavaScript program to remove the first n characters from a string. We will use slice and substring methods to remove the first n characters from a string.
ReadJavaScript program to get the first character of each word in a string. We will learn 3 different ways to solve this. By using a loop, ES6 map, split and using regex.
ReadJavascript program to count the number of digits in a string. We will solve this problem in two ways, by using regular expression or regex and by using a for loop.
ReadLearn how to implement bubble sort in JavaScript. Bubble sort sorts a list by comparing and swapping all pairs of adjacent elements. It is not the best sorting algorithm to use and it has O(n2) complexity.
Read