علم البيانات | DS2 Quizes – Telegram
علم البيانات | DS2 Quizes
965 subscribers
96 photos
2 videos
14 files
110 links
"قناة علمية متخصصة في مجال علم البيانات، قناة خاصة بالاختبارات MCQ ."
القناة العامة: @Computer_DS_1
النقاشات: @Computer_DS1
قناة الاختبارات: @Computer_DS_2
بوت التواصل والمشاركات : @DS_Combot
Download Telegram
Which of the following is the correct syntax of including a user defined header files in C++?
Anonymous Quiz
48%
#include <userdefined.h>
33%
#include "userdefined.h"
10%
<include> "userdefined"
10%
Both
🫡1
....... are like miniature programs and are called modules.
Anonymous Quiz
13%
Arrays
45%
Functions
17%
Pointers
25%
All of above
1
Which of the following is NOT a type of function?
Anonymous Quiz
15%
Main function
16%
Value-returning function
6%
Void function
63%
Parameterized function
Which of the following is NOT a type of formal parameter?
Anonymous Quiz
14%
Value parameter
18%
Reference parameter
35%
Constant parameter
33%
Default parameter
🔥41
🔥31👍1
2
Which of the following is the correct way to define a void function?
Anonymous Quiz
9%
functionName();
69%
void functionName(formal parameter list);
8%
functionName(formal parameter list);
15%
All of above
1
👍51
int myFunction(int x, int y = 10) {
  return x + y;
}

int main() {
  int a = 5;
  int b = myFunction(a, 20);
  cout << b << endl;
  return 0;
}
What is the output of the following code?
int myFunction(int x, int y = 10) {
return x + y; } int main() { int a = 5; int b = myFunction(a, 20); cout << b << endl; return 0; }
Anonymous Quiz
5%
5
7%
10
72%
25
16%
Error
2
Which of the following is the correct way to define a function with value parameters?
Anonymous Quiz
19%
int sum(int &x);
57%
int sum(int x);
8%
int sum(const int x);
17%
None of the above
1
What is the output of the following code?
void myFunction(int x, int y) {
x = x + y;
}

int main() {
int a = 5;
int b = 10;
myFunction(a, b);
cout << a << endl;
return 0;
}
What is the output of the following code?
void myFunction(int x, int y) {
x = x + y; } int main() { int a = 5; int b = 10; myFunction(a, b); cout << a << endl; return 0; }
Anonymous Quiz
4%
10
45%
15
46%
5
5%
Error
👍21😁1
What is the output of the following code?
void myFunction(int &x, int y=10) {
  x= x + y;
return x;
}

int main() {
  int a = 5;
  int b = 10;
  myFunction(a);
  cout << a << endl;
  return 0;
}
What is the output of the following code?
void myFunction(int &x, int y=10) {
  x= x + y; return x; } int main() {   int a = 5;   int b = 10;   myFunction(a);   cout << a << endl;   return 0; }
Anonymous Quiz
38%
5
12%
10
10%
25
39%
Error
👍2🔥1
What is the output of the following code?
int myFunction(int x, int y){
return x + y;
}

int main() {
int a = 5;
int b = 10;
int c = myFunction(a, b);
cout << c << endl;
return 0;
}
What is the output of the following code?
int myFunction(int x, int y){
return x + y; } int main() { int a = 5; int b = 10; int c = myFunction(a, b); cout << c << endl; return 0; }
Anonymous Quiz
3%
5
4%
10
82%
15
10%
Error
2
Which of the following is NOT a valid variable type in C++?
Anonymous Quiz
3%
int
5%
float
15%
string
77%
None of the above
👍1
the difference between a global variable and a local variable:
...........are declared inside a function, while .......... are declared outside of any function.
Anonymous Quiz
15%
global variables / local variables
8%
global variables / global variables
75%
local variables / global variables
2%
None of the above
3
Which of the following variables type in C++ that can only be accessed within the function it's declared in?
Anonymous Quiz
17%
global variable
58%
local variable
10%
Constant variable
15%
All of above.
🔥1