Explore a little.C ProgrammingC++HTMLVisual BasicSystem AnalysisE-CommerceBCA Notes
LEARN SOMETHING NEW

C++ Program to Find Size of int, float, double and char in Your System

Read4BCA learning libraryFree access

C++ Program to Find Size of int, float, double and char in Your System

//C++ Program to Find Size of int, float, double and char in Your System
//header files
#include<iostream.h>
#include<conio.h>

void main()
{

clrscr();
cout << "Size of char: " << sizeof(char) << " byte" << endl;
cout << "Size of int: " <<sizeof(int) << " bytes" << endl;
cout << "Size of float: " << sizeof(float) << " bytes" << endl;
cout << "Size of double: " << sizeof(double) << " bytes" << endl;
getch();

}

Output

C++ Program to Find Size of int, float, double and char in Your System example

You can also see a video how to run this program

This lesson preserves the original Read4BCA material. Some programming examples use older tools and syntax. View original page.