❮ Previous Next ❯

Data types in Java

It is important to state that java is a strongly type language.

We know that a variable is nothing but a named memory allocation.

A variable is defined by data type. That means the data type specify the size and type of values that can be stored.

When we want to use a variable in a program, we should first declared it as

int a;

Here a is a variable which can store integer data. int is called data type for example

A can store an integer number like 150 as

int a=150;

Here the value 150 is assigned to a which is called literal.

There are four basic prmitive datatypes.

  1. Integer Datatypes
  2. Double Datatypes
  3. Character Datatypes
  4. Boolean Datatypes
❮ Previous Next ❯

Follow Us




  Tutorials

Popular Links

Contact Us

address Plot No-741,2ND Floor
Opp. Bhagabati Temple,Jayadev Vihar
      Bhubaneswar-751013
      Email: info@silantechnology.com
      Phone: 0674-2361252
address
39877, sundale dr, apt#101, Fremont, California 94538, USA
       Phone: +1(262)388-7619

facebook twitter google linked in

© 2018 Silan Technology. All Rights Reserved