Rafi Fareen wrote:hi guys,
anyone can explain that:
byte c = 27;
i don't need to put caste for the above, because the compiler does that for me.
what about here ...
byte b = 10;
byte c = b+c; //i know that b+c will evaluate to integer (default behavior) ..
by why do i get compiler error when i assign b+c to c?
does that mean compiler puts caste automatically/implicitly only for literal assignments, not for expression assignments?