12th Class Class Computer Mcqs Chapter No 13 | 2nd Year Computer Mcqs Chapter Wise Pdf
Chapter No 13
Functions
1. Functions prototype for built-in functions are specified in choose which one is correct:
- source files
- header files
- object files
- image files
2. Global variables are created in
- RAM
- ROM
- Hard Disk
- cache
3. Which of the following is true about a function call choose which one is correct?
- Stops the execution of the program.
- Transfers control to the called function.
- Transfers control to the main function.
- Resumes the execution of the program.
4. The predefined functions that are part of C-language are called choose which one is correct:
- user-defined
- subprograms
- subroutines
- built-in functions
5. The functions that are defined by programmer are called choose which one is correct:
- user-defined
- subprograms
- subroutines
- built-in functions
6. Another name for built-in function is choose which one is correct:
- user-defined function
- library function
- ready-made function
- None
7. A function is called with the reference of its choose which one is correct:
- name
- parameter
- definition
- None
8. A function choose which one is correct:
- may return more than one values.
- may return only one value.
- cannot return any value.
- None of these
9. The actual values are passed to the function in choose which one is correct:
- function declaration
- function call
- function definition
- All
10. Which of the following looks for the prototype of functions used in a program choose which one is correct:
- Linker
- loader
- Compiler
- parser
11. The name of actual and formal parameters choose which one is correct:
- May or may not be same
- Must be same
- Must be different
- Must be in lowercase
12. Formal arguments are also called
- Actual arguments
- Dummy arguments
- Original arguments
- Referenced arguments
13. The printf() is a choose which one is correct:
- Built-in function
- User defined function
- Local function
- keyword
14. The actual body of the function is defined in choose which one is correct:
- function declaration
- function call
- function definition
- None
15. The last statement of the body of the function is choose which one is correct:
- break;
- continue;
- return
- shift
16. A built-in function choose which one is correct:
- Can not be redefined
- Can be redefined
- Can not return a value
- Should be redefined
17. In a C program two functions can have choose which one is correct:
- Same name
- Same parameters
- Same name and same parameters
- Same name but different parameters
18. The name of actual and formal parameters choose which one is correct:
- may or may not be same
- must be same
- must be different
- must be in lowercase
19. In C-language, subprograms are referred to as choose which one is correct:
- Methods
- Procedure
- functions
- modules
20. The predefined functions that are part of the programming language and can be used for different purposes are called choose which one is correct:
- Library functions
- Built-in functions
- user-defined functions
- Both a & b
21. The parameters specified in the function header are called choose which one is correct:
- formal parameters
- actual parameters
- default parameters
- command line parameters
22. __________ perform tasks that may need to be repeated many times.
- Condition
- Module
- Program
- Function
23. If the whole logic of program is contained in main function, it is called ___
- Structured Programming
- Un structured Programming
- Object Oriented Programming
- Modular Programming
24. Built in functions make our task ____________.
- Complex
- Lengthy
- Simple
- Technical
25. The parameters passed to a function in the function call are called choose which one is correct:
- formal parameters
- actual parameters
- default parameters
- command line parameters
26. Which of the following is the advantage of function choose which one is correct?
- Easy to write program
- Eliminate duplicate code
- Re-usability
- All of these
27. Function definition consists of choose which one is correct:
- function header
- Function body
- Both a & b
- None
28. The first line of function definition is called _________.
- Function Face
- Function Definition
- Function Header
- Function Name
29. The region of a program in which a variable is accessible, refers to its
- Area
- Scope
- Function
- Use
30. As soon as the control moves outside of their scope, local variable are
- Need to declare again
- Accessible to only a limited set of instructions
- Accessible
- Destroyed
31. Function declaration consists of choose which one is correct:
- function name
- Function return type
- number and types of parameters
- All
32. What is true about a function prototype choose which one is correct?
- It is also referred to as function declaration
- It is terminated with a semicolon (;)
- It is a single statement.
- All of these
33. A function that does not return anything has return type choose which one is correct:
- nothing
- float
- void
- null
34. The variables that are declared outside all blocks is called
- General Variables
- Variables
- Global variables
- Global Data Items
35. What is the return type of the function with prototype choose which one is correct: “int func(char x, float v, double t );”
- char
- double
- float
- int
36. The function declaration statement int abc (void); indicates that choose which one is correct:
- Return data type of function is void.
- return data type of function is int.
- function take no argument.
- function takes one argument of int type.
- Both (b) and (c)
37. The variables declared inside any function are known as choose which one is correct:
- global variable
- private variable
- external variable
- local variable
38. Which of the following is a valid function call (assuming the function exists) choose which one is correct?
- funct;
- funct x,y;
- funct();
- int funct();
39. Which of the following can return a value choose which one is correct?
- Function
- Procedure
- Both a and b
- None of Above
40. Data can be shared between functions using choose which one is correct:
- local variable
- static variable
- global variable
- register variable
41. Local variables are also called choose which one is correct:
- Automatic
- Normal
- Global
- None