Convert byte to Byte object - Java Language Basics

Java examples for Language Basics:byte

Description

Convert byte to Byte object

Demo Code

 
public class Main {
 
  public static void main(String[] args) {
    byte i = 10;//from   www . jav a  2  s .c  o  m
   
    Byte bObj = new Byte(i);
    System.out.println(bObj);
   
  }
}

Result


Related Tutorials