Sravani Alamanda has Published 28 Articles

Find digits not between the brackets using JavaScript Regular Expressions?

Sravani Alamanda

Sravani Alamanda

Updated on 08-Dec-2022 09:22:47

80 Views

In JavaScript, the regular expression [^0-9] is used to find the characters inside the bracket but not a digit. Except digit mentioned in the bracket, it will return the remaining characters from the text as an array. We all know about RegExp (Regular Expression) in JavaScript. RegExp is an object ... Read More

Are both addition and concatenation same in JavaScript?

Sravani Alamanda

Sravani Alamanda

Updated on 08-Dec-2022 08:43:53

1K+ Views

We can't say whether both are the same or both are different. In some cases, addition and concatenation will have the same result, but in some cases, they will be different. It is completely based on the type of variables. We will see it in detail below We use the ... Read More

Does JavaScript have a standard for commenting functions?

Sravani Alamanda

Sravani Alamanda

Updated on 26-Aug-2022 14:42:50

198 Views

Comments are used to explain the code flow and want to prevent the code from executing. In JavaScript, there are two types of comments. One is single-line comments, used to comment on the single-line code to prevent the code from executing or to explain the code. Another one is multi-line ... Read More

Does it make sense to use HTML comments on blocks of JavaScript?

Sravani Alamanda

Sravani Alamanda

Updated on 26-Aug-2022 14:41:42

78 Views

No, it is not recommended to use HTML comments to comment blocks of code. When JavaScript has first released some browsers didn’t have any support to understand the script. So a technique was then needed to hide the script code for older browsers. So that time the HTML comment within ... Read More

Find digits between brackets in JavaScript RegExp?

Sravani Alamanda

Sravani Alamanda

Updated on 26-Aug-2022 13:09:37

537 Views

In this tutorial, we learn how to find the digits between brackets using JavaScript RegExp. The ASCII values for the digits (0-9) start from 48 to 57. We denote the digits in the bracket as [0-9] in the regular expression. To find the digits in a range except for all ... Read More

Find digit with JavaScript RegExp.

Sravani Alamanda

Sravani Alamanda

Updated on 26-Aug-2022 13:03:17

547 Views

In this tutorial, we will see how to find digits (0-9) using JavaScript RegExp. ASCII value for digits [0-9] starts from 48 to 57. If you want to print any ASCII value for a digit, 48 needs to be added to that digit. We denote digits as \d in the ... Read More

Find a new line character with JavaScript RegExp.

Sravani Alamanda

Sravani Alamanda

Updated on 26-Aug-2022 12:55:22

3K+ Views

The new line character, we denote as . This is used to make a line break. ASCII code for is 10 and it is also called Line Feed (LF). Now, let's see how to find a new line character using RegExp. A RegExp is an object that specifies the ... Read More

Find a form feed character with JavaScript RegExp.

Sravani Alamanda

Sravani Alamanda

Updated on 26-Aug-2022 12:52:29

865 Views

Form feed character is page breaking ASCII control character. It is commonly used for page separators. When you want to insert a page break, the text editor can use this form feed. It is defined as \f and has an ASCII code value as 12 or 0x0c. RegExp is an ... Read More

Advertisements