2nd Year Computer Chapter 10 Notes
Important full 2nd Year Computer Chapter 10 Notes written by Professor Mr. Tayyab Shahzad. These notes are very helpful in the preparation of 2nd year computer chapter 10 important questions of 2nd year Computer Science for the students of the intermediate and these are according to the paper patterns of all Punjab boards.
Summary and Contents:
Topics which are discussed in the notes are given below:
- Important Multiple Choice Questions of 2nd year computer chapter 10 mcqs of 2nd-year Computer Science.
- Q1: The function getch ( ) is defined in: (a) stdio.h (b) string.h (c) math.h (d) conio.h
- Q2: getch ( ) function is used to input following number of character (s):
- (a) 1 (b) many (c) 2 (d) 3
- Q3: Which input function will not print the entered character on the screen?
- (a) scanf () (b) Getch ( ) (c) getche ( ) (d) getchar ( )
- Q4: The function clrscr ( ) is defined in: (a) stdio.h (b) math.h (c) conio.h (d) graphics.h
- Q5: Which of the following function is used to input data in C program?
- Important 2nd year computer chapter 10 mcqs with answers for Intermediate part-II students.
- (a) printf () (b) scanf ( ) (c) sqrt ( ) (d) get ( )
- Q6: Function which used to get input from the user:
- (a) printf () (b) scanf ( ) (c) clrscr ( ) (d) puts ( )
- Q7: The function getch ( ) is defined in: (a) stdio.h (b) conio.h (c) string.h (d) math.h
- Q8: The ampersand before the name of a variable denotes:
- (a) Actual value (b) Variable name (c) Address (d) Data type
- Q9: The escape sequence for carriage return is: (a) \a (b) \c (c) \r (d) \f
- Q10: The function that is used to display output on screen is called:
- (a) scanf (b) pow (c) display (d) printf
- Q11: How many variables can be used in one printf function?
- (a) One (b) Two (c) Ten (d) Many
- Important 2nd year computer chapter 10 important mcqs for Intermediate part-II students.
- Q12: Format specifier starts with symbol: (a) % (b) $ (c) # (d) @
- Q13: The escape sequence for backslash is: (a) \ (b) \a (c) \n (d) \m
- Q14: Which escape sequence is used to begin new line? (a) \a (b) \b (c) \m (d) \n
- Q15: Which of the following is not a valid escape code? (a) \t (b) \v (c) \y (d) \f
- Important 2nd year computer chapter 10 short questions for Intermediate part-II students.
- What is an input statement?: Ans: The data or instructions given to a program are called input. The data is provided to the
program by using some input device. Keyboard is standard input device. The input given
by keyboard is called standard input. The C language instructions that are used to take
input are called input statements.
- What is an output statement?
- What are standard input functions?
- What are standard output functions?
- Important 2nd year computer chapter 10 important long questions for Intermediate part-II students.
- What are is printf() function?: Ans: printf( ) function is used to send output of the program towards monitor. It can display
text, constants or value of variables on monitor. It can display text, constants and value of
variables in our desired format.
It is also called formatted output function. It is a library function defined in stdio.h header
file. The syntax of printf( ) function is as follow:
printf("string");
- What is a format specifier?
- What is field width in format specifier?
- What is an escape sequence?
- Important 2nd year computer chapter 10 long questions for Intermediate part-II students.
- What is getch() function?: Ans: This function is used to take a single character as input from keyboard. The character
taken from keyboard is transferred to variable. After typing a character there is no need
to press enter key. It is used to transfer a character to a variable without pressing enter
key. The character typed does not appear on screen.
- Important 2nd year computer chapter 10 long questions pdf download for Intermediate part-II students.
- What is getche() function?: Ans: The function getche( ) is used to take a single character as input from the keyboard. The
character taken from keyboard is transferred to char type variable. After typing a
character there is no need to press enter key. It is used to transfer a character to a
variable without pressing enter key.
- What is the function of \n escape sequence?
- What is the function of \t escape sequence?