Answer:
It is perfectly legal to assign a number to a variable and then assign a string to the same variable as follows
example
i = 10;
i = "string";
This is called variable typing
example
i = 10;
i = "string";
This is called variable typing
Previous Question | Next Question |
What is the difference between undefined value and null value? | Does JavaScript have the concept level scope? |