JavaScript Type Casting
JavaScript Type Casting
The Type Casting
is a method/technique of changing an entity from one data type to another.
Note: The Type Casting
is also known as type conversion, type coercion, and type juggling.
String to Number
In the following example, we will convert a string data type to number data type by using Number()
inbuilt JavaScript function.
Example
Number to String
In the following example, we will convert a number data type to string data type by using String()
inbuilt JavaScript function.
Example
Reminder
Hi Developers, we almost covered 97% of JavaScript Tutorials with examples for quick and easy learning.
We are working to cover every Single Concept in JavaScript.
Please do google search for:
Join Our Channel
Join our telegram channel to get an instant update on depreciation and new features on HTML, CSS, JavaScript, jQuery, Node.js, PHP and Python.
This channel is primarily useful for Full Stack Web Developer.