1. Home >
  2. Apps >
  3. Groups >

tipical program in java

Question asked by anandkumarjha in #Java on Oct 19, 2010
anandkumarjha
anandkumarjha · Oct 19, 2010
Rank C2 - EXPERT
Hello CEans,
can you please make me understand with this program how this will be executed?
class HexByte
{
public static void main(String args[])
{
char hex[]={'0','1','2','3','4','5','6','7','8','9','a','b','c','d','e','f',};
byte b=(byte)0xf1;
System.out.println("b=0x"+hex[(b>>4)&0x0f]+hex[b&0x0f]);
}
} Posted in: #Java

You must log-in or sign-up to reply to this post.

Click to Log-In or Sign-Up