answersLogoWhite

0


Best Answer

No. It has to be either NULL (Not yet Instantiated) or 0. Numeric objects cannot be empty.

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Can you have an empty Integer value in java?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Primitive java data types?

The primitive data types in Java are:int: integer value from -232 to 232floatdoublelong: integer value from -264 to 264byte: integer value from -128 to 128char: charactershort: integer value from -32768 to 32768boolean: true or false valueString (not actually a primitive data type)


How do you convert an int to object in java?

Java has auto-boxing introduced in Java 5 and converts ints to Integer objects as needed.Or you can explictly call Integer.valueOf(int) or new Integer(int) to return an Integer object with the value of the primitive int argument.Example:int i = 14; // i = 14Integer a = Integer.valueOf(i); // a = 14Integer b = new Integer(i); // b = 14or simplyInteger c = i;


Why using parseInt in java?

parseInt is a method in the Integer class in java and is used to parse string values into integer numbers. ex: int i = Integer.parseInt("10"); After the above line of code, the variable i will be assigned a value of 10 which is the numeric value of the string passed as argument to the parseInt method


What Double means in java?

I think it means that an integer,value, number of some sort can be returned for the object identified.


What does a char store?

In JavaA char in Java is a 16-bit integer, which maps to a subset of Unicode.In C A char in C is an 8-bit integer, which maps to standard ASCII.Note that in both Java and in C you can use a char value like a normal integer type: char c = 48;


What is mean by parse in java?

It is used to convert the value of one datatype into a value of another datatype. Example- Integer.parseInt(in.readLine); It converts given value to Integer datatype.


What is the purpose of integer Java?

Within Java, an integer is an Object, which is converse to the "int", which is a primitive. In reality, this means that for an integer, a method can be called upon it, whereas with a primitive, this is not the case.


Can you do a boolean test on integer in java?

No


What is java's keyword for the integer data type?

"int" is the keyword for integer


What is the Java integer class used for?

The Java Integer class is there to help with math. It is very useful and very recommended. To learn more information about it, go to the official Java page.


What is the default value of integer in java?

According to the JLS, the default value of an int is 0. The default value of an object of type Integer is null. Of course, this applies only to class members fields, as local method-level fields must be explicitly assigned a value before use.


How do you get the absolute value of positive integer?

The absoluate value of a positive integer is the integer itself.The absoluate value of a positive integer is the integer itself.The absoluate value of a positive integer is the integer itself.The absoluate value of a positive integer is the integer itself.