WorksheetsC++Day1
Total questions: 9
Worksheet time: 5mins
Which of the following commands is used to input data from the user?
أي من الاوامر التالية يستخدم لإدخال البيانات من المستخدم؟
cout<<variable ;
input( variable ) ;
cin << variable ;
cin >> variable ;
What does the word (endl) do?
endl في جملة الطباعة ماوظيفة الكلمة
Screen wipe
مسح الشاشة
Variable definition
تعريف المتغير
End the current line and clear the buffer
إنهاء السطر الحالي وتفريغ الذاكرة المؤقتة
Exit the program
إنهاء البرنامج بالكامل
أي مما العبارات التالية تستخدم لطباعة Hello متبوعة بقيمة المتغير x
Which of the following statements is used to print Hello followed by the value of the variable x?
cout<<"Hello "<< x ;
cout<<"Hello "<<"x";
cout<<"Hello >> x;
cout<<"Hello x";
Which symbol is used to write a single-line comment
أي رمز يستخدم لكتابة تعليق من سطر واحد
<<
//
/*
--
أي مكتبة يجب تضمينها لاستخدام cin , cout
Which library should be included to use cin, cout
iostream
iomanip
math
string
Which of the following lines defines a variable and assigns a value to it at the same time?
أي من الاسطر التالية يقوم بتعريف متغير وتخصيص قيمة له في نفس الوقت
int score; = 100
int score = 100;
score = 100
int score
Which of the following commands is defining a character variable?
أي الاوامر التالية سليم برمجيا لتعريف متغير حرفي
char g = "A";
char g = 'A' ;
character g = 'A';
g = 'A';
If you need to store the world's population, which is around 8 billion, which data type is most suitable?
اذا كنت بحاجة لتخزين عدد سكان العالم حوالي 8 مليار , أي نوع بيانات هو الانسب
int
char
double
long long
Which of the following variable names is correct
أي من أسماء المتغيرات التالية صحيح
_score
9score
score&ML
score ball
