excel higher secondary schoolb 5

18
[Turn over EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR. Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD [5 QUESTIONS]

Upload: sunesh-sj

Post on 23-Dec-2015

212 views

Category:

Documents


0 download

DESCRIPTION

cxzc

TRANSCRIPT

Page 1: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

[5 QUESTIONS]

Page 2: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

BOARD EXAM

Page 3: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

1. Basic statement in C++ are constructed using [Oct-08]

a) Tokens b) Symbols c) Functions d) Operators

2. How many methods are there for assigning data to the variables?[Oct-

12]a) 3 b) 2 c) 4 d) 5

3. Which object is used to read data the keyboard during runtime?[Mar-11]a) input b) cin c) cout d) inc

4. Which is predefined object that corresponds to the standard input stream?[Oct-

11]a) cout b) input c) cin d) inc

5. In which header file the declarations for the object cin are available?[Jun-07,Mar-

08,13,Oct-10] a) istream.h b) instream.h c) ostream.h d) oistream.h

6. Which header file comprises the combined properties of istream and ostream? [Oct-07]a) istream.h b) streamio.h c) iostream d) outstream.h

Page 4: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

7. A preprocessor directive stars with ….. [Mar-07,Oct-09,Jun-11]a) # b) # c) @ d) $ $

8. Which is the extraction or get from operator?[Oct-08,10,Mar-

10,11,12,13,Jun-12]a) >> b) << c) # d) $

9. …………….is a predefined object of standard output stream. [Jun-08]a) cin b) input c) cout d) output

10. Which is called the insertion operator or put to operator?[Mar-08,Jun-

10,11,Oct-12]a) >> b) >> = c) << = d) <<

11. A C++ program has primarily …………..sections. [Jun-10,Mar-13]a) 4 b) 3 c) 2 d) 5

12. On successful compilation, when the program is executed …………..will be automatically executed. [Oct-07]a) main ( ) function b) calling statement c) user defined function d) output statement

13. Which of the following is an assignment operator? [Jun-09,Mar-13]a) = b) > = c) < = d) = =

14. Program statements that cause a jump of control from one part of a program to another are called ……………statements. [Jun-09,Mar-13]a) assignment b) control c) input d) output

Page 5: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

15. Which statement creates branches for multiple alternatives sections of code, depending on the value of a single variable ? [Mar-07,Jun-08]a) for b) while c) switch d) do….while

16. Which is the simplest of all the decision statement? [Jun-07]a) switch b) if c) for d) white

17. Which is a multiple branching statement? [Oct-11,12,Jun-12]a) for b) if c) switch d) while

18. Which statement transfers control to one of the many possible points?[Jun-09,Mar-

12]a) switch b) if c) do…..while d) for

19. Every action block in switch statement should be terminated with a ………….statement. [Jun-08]a) break b) continue c) stop d) exit

20. Include …………..statement in action block in order to exit from switch statement. [Mar-08]a) continue b) break c) stop d) exit

21. There are ……….kinds of loops in C ++. [Oct-07]a) 3 b) 2 c) 5 d) 4

22. Which is called as exit –check loop? [Jun-08,11,12,Mar-12,Oct-08]a) for b) while c) do-while d) switch

23. Which loops is called as the entry –check loop? [Mar-07]a) switch b) while c) do while d) if

24. Which loops is an entry controlled loop? [Oct-09]

Page 6: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

a) for b) while c) do while d) switch

25. Which loop is used when an action is to be repeated for a predetermined number of times? [Oct-08]a) while b) for c) do while d) switch

26. Which statement forces the next iteration of the loop to take place?[Jun-

09,10,Oct-09,10]a) break b) continue c) stop d) exit

27. Which statement accomplishes jump from the current loop or exit the current loop? [Mar-10,Jun-11]a) stop b) continue c) break d) quit

28. A program written in high level language is called as ……….[Mar-07,Oct-

08]a) object code b) complier c) executable file d) source code

29. The machine readable from of a program is called as ……[Jun-08,11,Oct-10,12]

a) source code b) object file c) executed file d) application file

30. …………..creates object files from source code. [Mar-08,10,Oct-11]a) complier b) executable file c) object file d) application file

31. Which is a multiple branching statement where, based on a condition, control is transferred to one of many possible points [Mar-12]a) if b)switch c) do d) for

Page 7: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

32. Which statement is used to terminates the loop irrespective of the expression in C++ [Mar-12]a) exit b) continue c) while d) break

33. The statement int A;b; is invalid because [Jun-07,09,Oct-09]a) Only one variable should be given b) Capital A is not allowed c) Variable should is not allowed d) All of these

34. How many times the following loop will be executed? For (i=1; i<6; i ++) [Jun-

07]a) 1 b) 5 c) 6 d) 7

35. The break statement would exit only [Jun-07,09]a) current loop b) current function c) current program d) none of these

Read the following C++ program carefully and answer the Questions from 36 to 40 #include<iostream .h>void main () {int num=2;do{cout<<num*num<<’\t’;num + =1;} while (num<6);}

36. Name the control variable used in the program. [Mar-09]a) num b) + = c) \t d) None of these

37. What is the test expression (conditional) used? [Mar-09]

Page 8: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

a) num b) num * num c) (num < 6) d) None of these

38. How many times will the loop be executed? [Mar-09]a) 6 b) 4 c) 5 d) 3

39. What is the output of the following program? [Mar-09]a) 2 4 9 16 25 b) 6 5 6 8c) 4 9 16 25 d) 0 4 9 25

40. What type of loop statement is used in the program? [Mar-09]a) Entry check loop b) Exit check loop c) Entry controlled loop d) Selection loop

41. How many times the following loop will be executed? For (i=1; i=<30; i=++)[Mar-

10]a) 1 b) 29 c) 30 d) 31

42. What is the error throw by the complier for the following snippt?[Mar-

10]if (a>b);cout << “Greater” elsecout<< “Lesser”;a) Misplaced if b) Misplaced else c) Misplaced if –else d) Misplaced else –if

43. How many times the following loop will be executed? For (i=0; i=++)[Jun-

10]a) Only one b) Nine times c) Ten times d) Not executed

Page 9: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

44. Which is linked with libraries to create an executed file? [Jun-10]a) Source code b) Object code c) Programs d) Computer

45. The appropriate declaration statement to initialize the variable ‘name’ with the value “Abdual Kalam” is [Oct-10]a) char name = “Abdual Kalam”;b) char [ ] name =“Abdual Kalam”;c) char name [ ] = Abdual Kalam;d) char name [ ] =“Abdual Kalam”;

46. While < (condition)> {…………….} loop is called as [Mar-11]a) entry – check loop b) exit –check loop c) multi-check loop d) nested loop

47. Program statement that causes jump from one part of the program to another is [Mar-11]a) Control Structure b) Assignment Statement c) Input/ Output Statement d) Conditional Structure

48. In C++, which should be declared or defined before they are used in a program? [Oct-11,Mar-12]a) Data base b) Variable c) Objects d) Class

49. The variable used in for loop is called [Oct-11]a) Static variable b) Counting variable c) Control variable d) for variable

50. Which of the following is the in valid variable declaration? [Mar-08,10]a) int a,b; b) int a; int b;c) int a; float b; d) int a; b;

Page 10: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

51. The invalid variable declaration statement in C++ in the following is [Mar-12]

a) int a,b; b) int a= 10; float b;c) int a;b d) int a; float b = 10

52. What is the output of the following snippet? [Oct-12]int b= 10>20;if {b}{ cout<< “True Block”;}else{

cout << “Else Block”;}a) Else Block b) True Block c) True Block Else Block d) Else Block True Block

Page 11: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

CREATED

1. How many methods are there for assigning date to the variable in C++ ?a) 2 b) 3 c) 4 d)5

2. Date is read from the keyboard during run time by using the object…………a) cin b) cni c) nic d) nic

3. Cin is a predefined object which corresponds to a standard ……..streama) input b) output c) process d) 10

Page 12: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

4. ………file comprises of all standard declarations and definitions for predefined functions

a) header b) footer c) istream d) iostream

5. The extraction operator that extracts date from the input stream object is……….a) cin b) cout c) cio d) count

6. Program statements that causes jumps are called as……… statements are structures.a) control b) assignment c) increment d) decrement

7. ……..statement which choose between two alternatives. a) if – else b) if c) for d) while

8. The multiple branching statement is……….statement?a) if b) switch c) for d) while

9. Switch expression should be evaluated to an ………..constant only.

a) integer b) string c) variable d) float

10. ----------is an entry controlled loop and is used when an action is to be repeated for a predetermined number of times .a) for b) switch c) if d) break

11. ………… statement is used when a loop’s execution is terminated when the text condition evaluates to false.

a) continue b) break c) if d) switch

12. A loop embedded within another loop is calleda) Nested b) Loop c) Break d) continue

Page 13: Excel Higher Secondary Schoolb 5

[Turn over

EXCEL HIGHER SECONDARY SCHOOL, 17/190A, Awai Farm Lane, THIRUVATTAR.Tel: 04651-282319 Fax: 04651-282312 email: [email protected] website: www.excelschools.edu.in

X11 QUESTION BANK 12.BASIC STATEMENTS X11 ONE WORD

* * * * * * * *