viki
05-27-2010, 12:01 AM
Today's Paper
Q1: Write down the general syntax of switch statement. 2 Marks
Q2: Why we close a file after use? 2 Marks
Q3: When a pointer is incremented then how many bytes will it move to change its address?
2 Marks
Q4: If there are 2n element in an array then what would be the number of iterations required to search a number using binary and linear search? 3 Marks
Q5: write down the functions definition if we want to pass the argument to a function by reference without changing the values stored at address. 5 Marks
Q6: What will be the output of the following code segment 5 Marks
, int x= 6;
int y;
x = x << 1;
y = x >> 1;
cout << “x = ” << x << “\n”;
cout << “y = ” << y;
Q1: Write down the general syntax of switch statement. 2 Marks
Q2: Why we close a file after use? 2 Marks
Q3: When a pointer is incremented then how many bytes will it move to change its address?
2 Marks
Q4: If there are 2n element in an array then what would be the number of iterations required to search a number using binary and linear search? 3 Marks
Q5: write down the functions definition if we want to pass the argument to a function by reference without changing the values stored at address. 5 Marks
Q6: What will be the output of the following code segment 5 Marks
, int x= 6;
int y;
x = x << 1;
y = x >> 1;
cout << “x = ” << x << “\n”;
cout << “y = ” << y;