Variables Example Program in Dart


Example Program:

Here is the simple program for printing the basic example of variables in dart.

Source Code

void main()
{
   var a=10;
   print(a.runtimeType);
   int b=25;
   print('The Value of b is ${b}');
   double x=25.3;
   print(x.runtimeType);
   String y='Joes';
   print(y.runtimeType);
   dynamic z;
   z=10;
   print('The Value of Z ${z} type : ${z.runtimeType}');
   z=25.5;
   print('The Value of Z ${z} type : ${z.runtimeType}');

}
To download raw file Click Here

Output

int
The Value of b is 25
double
String
The Value of Z 10 type : int
The Value of Z 25.5 type : doubl

Learn All in Tamil © Designed & Developed By Tutor Joes