Hi All,
Which one is correct way
Code:if(i==4) { /*Do something*/ }
consideringCode:if(4==i) { /*Do something*/ }is any type of variable,Code:i
Also sometimes I have seen this
considering u8 as unsigned char type and i is any type of variable.Code:if(i==(u8)4) { /*Do something*/ }
what is the significance of typecasting the decimal value 4 to unsigned char?
Thanks in advance