+ 2

Is null and 0 are equal

13th May 2017, 4:47 PM
Harish
4 ответов
+ 5
It depends upon the language. In complex languages like C++ and maybe JS, its a no. In SQL, PHP and CSS its usually yes. In general terms they are the same. Void also means zero, null or nothing. ("Not in programming")
13th May 2017, 4:59 PM
Rugved Modak
Rugved Modak - avatar
+ 5
@Vrishal Prajapati that is true in all cases
13th May 2017, 5:01 PM
Rugved Modak
Rugved Modak - avatar
+ 2
No, null means the the variable has no value. whereas 0 means that variable has value.
13th May 2017, 4:59 PM
Vishal Prajapati
0
Even in SQL null is not 0 as null+1=null and 0+1=1.
14th May 2017, 12:02 AM
1of3
1of3 - avatar