Category: Advanced Chapters
-
Insertion Sort Algorithm
The Insertion Sort is a sorting algorithm that works very similar to the way we sort the playing cards when we play. The arrangement of elements in a sorted manner is done through insertion sort. In this algorithm, the array will be divided virtually into two parts which are sorted and unsorted parts. The values…
-
HTTP Requests
Http is a protocol, stands for hypertext transfer protocol. The http requests are used to communicate with web servers. It allow us to send requests to a server and get responses. These can be used to fetch data, submit forms, upload file and more. HTTP Methods These are the most commonly used HTTP methods: Ways…
-
Generate Colors
Generating colors are quite handy while working on web development projects. For beautiful UI, we need to use different colors. In this chapter, we will learn how to generate colors in JavaScript. Generating Random Hex Color The Hex (Hexadecimal) code is a six-digit code and a three-byte hexadecimal number that is used to represent the…
-
Filter Method
JavaScript – Filter Method In JavaScript, the filter() method is used to create a new array with elements that pass a certain condition. It takes a callback function as its argument which is executed for each and every element in the array. If the callback function returns true, the element is added to the new array or…
-
Date Validation
In JavaScript, we can validate the date. A date should be in a particular format or it should be in a particular range and should be valid. Why we validate a date ? Lets understand why we need to validate the date in JavaScript by example. Suppose, you have developed an application that takes some…
-
Current Date/Time
Date and time are the most common things we often need to use in applications. In javascript, we can use Date object to get the current date and time. To solve all the problems, we will just create an object of date class and will use its various methods to get the current date and…
-
Callback Function
In JavaScript, functions are considered as objects, which means they can be used just like any other value we pass to the function. So, we can pass them as parameters to other functions just like we do with variables or objects. When you pass a function as a parameter, it will be called or even…
-
Base64 Encoding
Encoding is the process of converting text from one data format to another. In computer science terms,encoding is the process of converting a text into a cipher text. Encoding is different from the Encryption process. Base64 encoding is generally used for encoding binary data, such as images, audio, video, etc. It is a group for…
-
Data Structures
Data Structures are the programming constructs which are used to store and organize data. We can write effective efficient programs using these, while performing data operations. JavaScript provides various data structures for different operations. In this tutorial, we will learn about the different data structures in JavaScript. Data Structures in JavaScript We have the following…
-
Recursion
Recursion is a process in which a function calls itself. It helps when we need to solve a problem that can be break down into smaller problem of the same type. What is Recursion? The word recursion came from the recurring, meaning comes back to again and again. The recursion function is the function calling…