/* misc.cpp -- various constructs */

#include <iostream>
#include <cstdlib>

using namespace std;


void main(void) {
  int answer = 1;
  short x = 1;
  long y = 2;
  float u = 3.0;
  double v = 4.4;
  long double w = 5.54;
  char c = 'p';

  /* __DATE__, __TIME__, __FILE__, __LINE__ are predefined symbols */
  cout << "Date : " << __DATE__ << endl;
  cout << "Time : " << __TIME__ << endl;
  cout << "File : " << __FILE__ << endl;
  cout << "Line : " << __LINE__ << endl;

  /* The size of various types */
  cout << "The size of int    " << sizeof(answer) << endl;
  cout << "The size of short  " << sizeof(x) << endl;
  cout << "The size of long   " << sizeof(y) << endl;
  cout << "The size of float  " << sizeof(u) << endl;
  cout << "The size of double " << sizeof(v) << endl;
  cout << "The size of long double " << sizeof(w) << endl;
  cout << "The size of char   " << sizeof(c) << endl;

  /* Executing a System Command Language command */
  system("ls");
}

/* Output is:
Date : Nov 24 1998
Time : 12:20:41
File : misc.cpp
Line : 22
The size of int    4
The size of short  2
The size of long   8
The size of float  4
The size of double 8
The size of long double 8
The size of char   1
a.out
array.cpp
euclid.cpp
ffile1.cc
integers.out
integers.txt
power2.cpp
prime1.cpp
quicksort.cpp
studentarray.cpp
three.cpp
tmp.cpp
tokens.cpp
transpose.cpp
triangle.cpp
typescript
unsigned.cpp

 */
