79194560

Date: 2024-11-16 05:19:28
Score: 0.5
Natty:
Report link

Primitive Vs Reference Data Types Primitive Vs Reference Data Types

Primitive Data : Primitive data types are commonly used data types which includes 7 datatypes in ES6 JavaScript, i.e String, Number, Boolean, Undefined, Null, BigInt and Symbols. Primitive values are stored in Stack for faster access as they are passed by value.

Reference Data Types : Reference data types are advance data types like Functions, Arrays, Objects, Map and Sets. They are stored on heap. Reference data types are passed by reference, not value. This means two variables with same reference object has same reference in memory.

JavaScript Data Types Post: JavaScript Data Types

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (0.5):
Posted by: Avinash Malhotra