JavaScript Data Types

JavaScript is a loosely typed and dynamic language. Variable can be assigned or reassigned anytime. In JavaScript, there is no need to declare the type of variable like C/C++, Java,etc.You can assign a value directly. JavaScript also allows values called primitive types. These are well known types in all programming langauges. Primitive Types are: <mark … Read more

Groups And Range Of Characters

In regular expression, sometimes we need to match a group of characters or a range of characters. These kind of expressions are written within a bracket notation. In this post, we will explore these kind of expressions with examples. List of Range Expressions The following table demonstrate the grouped expressions and their meaning. Expression Meaning … Read more

Regular Expression Flags

In the previous article, you learned about regular expression being pattern of search. Regular expression uses flags that are optional and perform searches that are global or case-insensitive. You can use these searches separately or together to do search. List of Flags Here is a list of flags commonly used with regular expressions. Flag Meaning … Read more

Regular Expression Basics

The regular expression is sequence of characters that makes a pattern. The pattern is used for searching text in data. You can create a simple pattern or a complex regular expression in JavaScript. The regular expression does two kind of work – search and replace text using several of available string methods. Syntax The regular … Read more

JavaScript Do-While Loop

The JavaScript do-while loop is similar to the while loop about which you studied earlier. Instead of testing the condition at the beginning of the loop, a do-while loop test the condition after the loop body. This guarantees that the loop will execute at least once. Syntax – do-while Here is the syntax of the … Read more

JavaScript While Loop

The JavaScript version of while loop is similar to other programming languages such as C++, Java. The loop takes initial value, checks for condition, and execute the loop and finally increment the loop. The section below describe the syntax and each component of the JavaScript while loop. Syntax – <mark style="background-color:rgba(0, 0, 0, 0);color:#b81414" class="has-inline-color">While</mark> … Read more

JavaScript For Loop

JavaScript for loop is similar to the for loops in other programming languages like C, C++, and Java. The for loop takes and initial value, checks for terminating conditions, and increment the iteration as long as the continue is true. This article we will talk about different for loop structures in JavaScript. Some of them … Read more

JS: splice() Method

The js<span style="color:#cf2e2e" class="tadv-color">splice()</span> method is like the slice() method and extract/remove or change/add new specified elements from/to an array. This method changes the original array. The js splice method takes three parameters – start index, number of elements to removed/added, and items that need to added. Index – This parameter tells where to start … Read more

JS: slice() Method

The<span style="color:#cf2e2e" class="tadv-color"> slice()</span> method is part of JavaScript Array class. It extract certain elements from an array and returns a new array. There are different ways to select elements using <span style="color:#cf2e2e" class="tadv-color">slice()</span> in JavaScript. The<span style="color:#cf2e2e" class="tadv-color"> slice()</span> method takes two parameters – start index and the end index of an array. It … Read more

Ads Blocker Image Powered by Code Help Pro

Ads Blocker Detected!!!

We have detected that you are using extensions to block ads. Please support us by disabling these ads blocker.