Convert short primitive to Short object - Java Language Basics

Java examples for Language Basics:short

Description

Convert short primitive to Short object

Demo Code

 
public class Main {
 
  public static void main(String[] args) {
    short s = 10;
    Short sObj = new Short(s);
    System.out.println(sObj);/*from  www.ja  v  a2s.c o  m*/
   
  }
}

Result


Related Tutorials