In Programming language a data type determines what kind of data that variable holding.
e.g. In C programming language int count; would mean that the count variable only can hold integer data type. If someone try count = “hello” a compiler error will be thrown. This kind of data type is called static data type.
Primitive are elemental single value data type. Elemental means they have unique characteristic and they serve unique purpose.
null : A specific memory space which can be used to point any variable. You can assign null to a variable. It may look similar with undefined but remember null can be used by you as per situation and can be used for comparison e.g. count === null .
string : It holds charter data set enclosed within “” or '' .
boolean : it holds true/false .
In this case even though 2 is number it treats like a string and it gets added with 3 to produce string concatenation result 23.
This type of forcing data type from one to another type based on situation is named as coercing.