answersLogoWhite

0


Best Answer

In Java, you can use either a float or a double

User Avatar

Wiki User

14y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

10y ago

float (which uses 4 bytes), and double (which uses 8 bytes, and therefore has more significant digits).

This answer is:
User Avatar

User Avatar

Wiki User

11y ago

double and float

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What are two Java primitive types store floating-point numbers?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

What are primitive variables?

Primitive variables are variables that are not objects and carry primitive values like numbers, boolean etc. The primitive data types in java are:intbytefloatcharlongbooleanshortdouble


Define and give three examples of primitive data types?

A primitive variable can be one of eight types: char, boolean, byte, short, int, long, double, or float. Once a primitive has been declared, its primitive type can never change, although in most cases its value can change. they are used to store values like name, age, salary etc.


What is primary data type in C?

The terms "primary data type" and "secondary data type" are not exactly correct when working in C. Instead, C has what are called "primitive data types" or, in some references, "basic types" - types which can be affected by arithmetic operators. Other data types include structs, arrays, and unions. Structs, arrays and unions cannot be affected as a whole by arithmetic operators, although the members within that are primitive data types can be. Pointers can technically be affected by arithmetic operators, particularly +, -, ++ and --, but because their values are expected to be used as addresses, they're not considered to be primitive in nature. There are three primitive data types in C: integers, real numbers and complex numbers. Integers have no decimal points and can be signed or unsigned, and real and complex numbers are signed and have decimal points. Boolean types are represented by integers, most commonly "int" under Posix-style systems. More information about primitive data types can be found in the related links below


Variables as object in java?

There are two main categories of variables in Java. They are primitive and non primitive. Primitive data types are the basic data types like int, float, char etc. These are not objects. The other non primitive data types are all types of Java Objects. Example: String, ArrayList etc.


Data types in c primitive and non primitive?

Primitive types are the data types provided by a programming language as basic building blocks. Primitive types are also known as built-in types or basic types. Depending on the language and its implementation, primitive types may or may not have a one-to-one correspondence with objects in the computer's memory. However, one usually expects operations on primitive types to be the fastest language constructs there are. Integer addition, for example, can be performed as a single machine instruction

Related questions

What are primitive variables?

Primitive variables are variables that are not objects and carry primitive values like numbers, boolean etc. The primitive data types in java are:intbytefloatcharlongbooleanshortdouble


Define and give three examples of primitive data types?

A primitive variable can be one of eight types: char, boolean, byte, short, int, long, double, or float. Once a primitive has been declared, its primitive type can never change, although in most cases its value can change. they are used to store values like name, age, salary etc.


What is primary data type in C?

The terms "primary data type" and "secondary data type" are not exactly correct when working in C. Instead, C has what are called "primitive data types" or, in some references, "basic types" - types which can be affected by arithmetic operators. Other data types include structs, arrays, and unions. Structs, arrays and unions cannot be affected as a whole by arithmetic operators, although the members within that are primitive data types can be. Pointers can technically be affected by arithmetic operators, particularly +, -, ++ and --, but because their values are expected to be used as addresses, they're not considered to be primitive in nature. There are three primitive data types in C: integers, real numbers and complex numbers. Integers have no decimal points and can be signed or unsigned, and real and complex numbers are signed and have decimal points. Boolean types are represented by integers, most commonly "int" under Posix-style systems. More information about primitive data types can be found in the related links below


Variables as object in java?

There are two main categories of variables in Java. They are primitive and non primitive. Primitive data types are the basic data types like int, float, char etc. These are not objects. The other non primitive data types are all types of Java Objects. Example: String, ArrayList etc.


Data types in c primitive and non primitive?

Primitive types are the data types provided by a programming language as basic building blocks. Primitive types are also known as built-in types or basic types. Depending on the language and its implementation, primitive types may or may not have a one-to-one correspondence with objects in the computer's memory. However, one usually expects operations on primitive types to be the fastest language constructs there are. Integer addition, for example, can be performed as a single machine instruction


What types of variables are useful to programmer?

All variable types in a given computer language are useful to a programmer, otherwise they would not be included in the language. However, a specific program may not need to use all types to solve a given problem.In general, there are two distinct categories of variable types: primitive types and derived types.A primitive variable type is one whose definition is stated by the program language itself. Common primitive variable types are Integers, Characters, Floating Point numbers, and Arrays. The meaning of these types is fixed, and cannot change. Most languages seldom have more than a half-dozen primitive variable types.A derived variable type is one which is created by combining two or more primitive types together. It is possible to create a huge variety of different derived variable types. Items such as HashMaps, Strings, and Linked Lists are common derived variable types.


List the eight basic data types used in java and give examples?

The 8 primitive data types are byte, short, int, long, float, double, boolean and char boolean is used to store logical values true/false char is used to store single digit characters. 'Y', 'X' etc the remaining data types are used to store a wide variety of numbers.


What do you mean by vectors only hold objects not primitive data types?

It means that you can only store values like Integer, String etc in a Vector and not values like int, float etc. int, float, double etc are primitive data types. collections by their default behavior can hold only objects and not primitives.


What is the difference between primitive fish and the most advanced types?

primitive fish are ones that have more skeleton weres advanced types tend to be more of muscles


Why is class called non primitive in c plus plus?

Primitive refers to base types, like int and char. Classes are complex types, combining primitives with other classes or structures, and are therefore non-primitive.


What are the primitive types of artificial neuron?

I don't now


Do the primitive datatypes in java have objects?

No Primitive data types do not have objects. As of Java 1.5, all primitive types in Java have "wrapper" classes. These classes serve two purposes: # They keep all type-specific methods together in one place. # They allow primitive types to be used in situations which take advantage of generics (also introduced in Java 1.5).