مقدمة في البرمجة باستخدام لغة++C مقدمة في البرمجة باستخدام لغة++C

آخر الأخبار

جاري التحميل ...

Data Types

C++ Data Types

As explained in the Variables chapter, a variable in C++ must be a specified data type:

Example

int myNum = 5;               // Integer (whole number)
float myFloatNum = 5.99;     // Floating point number
double myDoubleNum = 9.98;   // Floating point number
char myLetter = 'D';         // Character
bool myBoolean = true;       // Boolean
string myText = "Hello";     // String

Basic Data Types

The data type specifies the size and type of information the variable will store:

Data TypeSizeDescription
boolean1 byteStores true or false values
char1 byteStores a single character/letter/number, or ASCII values
int2 or 4 bytesStores whole numbers, without decimals
float4 bytesStores fractional numbers, containing one or more decimals. Sufficient for storing 6-7 decimal digits
double8 bytesStores fractional numbers, containing one or more decimals. Sufficient for storing 15 decimal digits


resources

https://www.w3schools.com/cpp/cpp_data_types.asp

watch this video





عن الكاتب

cpp

التعليقات


اتصل بنا

إذا أعجبك محتوى مدونتنا نتمنى البقاء على تواصل دائم ، فقط قم بإدخال بريدك الإلكتروني للإشتراك في بريد المدونة السريع ليصلك جديد المدونة أولاً بأول ، كما يمكنك إرسال رساله بالضغط على الزر المجاور ...

جميع الحقوق محفوظة

مقدمة في البرمجة باستخدام لغة++C