By QB365 on 13 May, 2022
12th Standard Computer Science English Medium Function Important Questions
latest Sample Question Papers12th Standard
Computer Science
The small sections of code that are used to perform a particular task is called
Subroutines
Files
Pseudo code
Modules
Which of the following is a unit of code that is often defined within a greater code structure?
Subroutines
Function
Files
Modules
Which of the following is a distinct syntactic block?
Subroutines
Function
Definition
Modules
The variables in a function definition are called as
Subroutines
Function
Definition
Parameters
The values which are passed to a function definition are called
Arguments
Subroutines
Function
Definition
Which of the following are mandatory to write the type annotations in the function definition?
{ }
( )
[ ]
< >
Which of the following defines what an object can do?
Operating System
Compiler
Interface
Interpreter
Which of the following carries out the instructions defined in the interface?
Operating System
Compiler
Implementation
Interpreter
The functions which will give exact result when same arguments are passed are called
Impure functions
Partial Functions
Dynamic Functions
Pure functions
The functions which cause side effects to the arguments passed are called
Impure function
Partial Functions
Dynamic Functions
Pure functions
Which of the following are expressed using statements of a programming language?
Functions
Algorithm
Interface
Implementation
What must the used when a bulk of statements to be repeated for many number of times?
Algorithm
Program
Subroutines
Parameters
Which of the following contains a set a code that works an many kinds of input and produces a concrete output?
Function
Algorithm
Arguments
Language
Which of the following are the values which are passed to a function definition?
Parameters
Algorithm
Data types
Arguments
The function definition is introduced by the keyword
def
rec
let
infer
The recursive function is defined using the keyword
let
let rec
name
infer
A function definition which call itself is called
user defined function
built-in function
derived function
recursive function
Which of the following is a description of all functions in object oriented programming language?
Implementation
parameter
Interface
Arugument
Which of the following is an instance created from the class?
parameter
function
subroutines
object
Which of the following is an example of impure function?
Strlent( )
randomt( )
sqrfi( )
puref( )
In which type of function the return type is solely depends on its argument passed?
pure
impure
parameterized
monochromatize
In which type of function the return type does not solely depends on its argument passed?
Pure
Parameterized
Impure
Monochromatize
Subroutines are called as________
Algorithm
Interface
Parameters
Function
_______are the variables in a function definition.
Arguments
Parameters
Identifiers
Operators
Explicitly_________the types can help with debugging.
defining
annotating
informing
computing
All functions are________ definitions.
static
dynamic
algorithmic
static
A_________ combines the external interface with an implementation of the interface
parameter without type
class declaration
function definition
parameter with type
In object oriented programs__________ are the interface
Implementation
parameters
Interface
Arguments
In object oriented programs, how the object is processed and executed is__________
Implementation
Interface
recursion
function
Strlen is an example________function.
user defined
impure
pure
recursive
Evaluation of__________ functions does not cause any side effects to its output?
Impure
pure
Recursive
built-in
Which of the following functions that build the abstract data type?
Constructors
Destructors
recursive
Nested
Which of the following functions that retrieve information from the data type?
Constructors
Selectors
recursive
Nested
The data structure which is a mutable ordered sequence of elements is called
Built in
List
Tuple
Derived data
A sequence of immutable objects is called
Built in
List
Tuple
Derived data
The data type whose representation is known are called
Built in datatype
Derived datatype
Concrete datatype
Abstract datatype
The data type whose representation is unknown are called
Built in datatype
Derived datatype
Concrete datatype
Abstract datatype
Which of the following is a compound structure?
Pair
Triplet
single
quadrat
Bundling two values together into one can be considered as
Pair
Triplet
single
quadrat
Which of the following allow to name the various parts of a multi-item object?
Tuples
Lists
Classes
quadrats
Which of the following is constructed by placing expressions within square brackets?
Tuples
Lists
Classes
quadrats
Which of the following is a powerful concept that allows programmers to treat codes as objects?
Encapsulation
Data Abstraction
Inheritance
Polymorphism
Which of the following provides modularity?
Datatypes
Subroutines
Classes
Abstraction
ADT expansion is
Abstract Data Template
Absolute Data Type
Abstract Data Type
Application Development Tool
Which of the following is a type for objects whose behavior is defined by a set of value and a set of operations?
User-defined datatype
Derived datatype
Built-in datatype
Abstract datatype
ADT behavior is defined by
(i) Set of Variables
(ii) Set of Value
(iii) Set of Functions
(iv) Set of Operations
i, ii
ii, iii
ii, iv
i, iii
The process of providing only the essentials and hiding the details is known as
Functions
Abstraction
Encapsulation
Pairs
Which of the following gives an implementation independent view?
Abstract
Concrete
Datatype
Behavior of an object
How many ways to implement an ADT?
Only one
Two
Three
Many
Which of the following are implemented using & lists?
Singly linked list ADT
Doubly Linked list ADT
Queue ADT
All of these
Which of the following replicate how we think about the world?
Queue ADT
Data Hiding
Data Abstraction
Stack ADT
To facilitate data abstraction, How many types of functions are created?
2
3
4
Only one
Which of the following function that facilitate the data abstraction?
Constructors
Destructors
Selectors
a and c
Which of the following are functions that build the abstract datatypet?
Constructors
Destructors
Selectors
All of these
Which of the following extract the information of the object?
Constructors
Functions
Selectors
Destructors
In which data representation, a definition for each function is known
User defined
Buil-in
Abstract
Concrete
How many parts are the!"ein the program?
2
3
4
Many
To implement the concrete level of data abstraction the language python provides a compound structure called
ADT
Concrete data
Pair
User defined function
Which of the following is contracted by placing expressions within square brackets separated by commas?
List
Tuple
Set
Dictionary
How many values can be stared in the list?
4
10
100
Multiple
List can also be called as
Functions
Class
Structure
Pairs
How many ways are there to represent pair datatypet?
2
4
3
5
Color = ('red', 'green, 'blue') is an example of
Dictionary
List
Set
Tuple
Which of the following does not allow us to name the various parts of a multi-item object?
List
Triple
Pair
All of these
Which of the following defines a data abstraction by grouping related data items?
List
Pair
Class
Tuple
Which of the following as bundled data and the functions that work on that data?
Object
Pair
List
Class
I: = [10,20] is an example
Tuple
Set
List
Dictionary
CDT expansion is
Collective Data Type
Class Data Type
Concrete Data Type
Central Data Type
Data Abstraction allows programmers to treat code as_______
Objects
Classes
Members
Parameters
________are the representation for Abstract Data types.
Objects
Classes
Functions
Lists
Classes are the representation for___________
Abstract datatype
Built-in datatype
Concrete datatype
Essential datatype
The____________ can be implemented using singly linked list or doubly linked list
Tuple ADT
List ADT
Function ADT
List ADT
The basic idea of ________ is to structure programs so that they operate on abstract dat(a)
Encapsulation
Polymorphism
Data type
Data Abstraction
A________ data representation is defined as an independent part of the program.
Abstract
Concrete
List
Tuple
______ are functions that retrieve information from the data type.
Constructors
Selectors
List
Tuple
______is made up of list or Tuples
Set
Pair
Dictionary
Control Structures
A ________ is a comma separated values surround with parentheses.
List
Tuple
Set
Dictionary
Tuple is constructed by using ______ and________
( )
[ ]
<>
{}
A________ is not just data, it has functions defined within it.
Class
List
Pair
Object
List is constructed by using ________ and _________.
( ), ,
< >,;
[ ], ,
[ ],:
Which of the following refers to the visibility of variablesin one part of a program to another part of the same program.
Scope
Memory
Address
Accessibility
The process of binding a variable name with an object is called
Scope
Mapping
late binding
early binding
Which of the following is used in programming languages to map the variable and object?
::
:=
=
==
Containers for mapping names of variables to objects is called
Scope
Mapping
Binding
Namespaces
Which scope refers to variables defined in current function?
Local Scope
Global scope
Module scope
Function Scope
The process of subdividing a computer program into separate sub-programs is called
Procedural Programming
Modular programming
Event Driven Programming
Object oriented Programming
Which of the following security technique that regulates who can use resources in a computing environment?
Password
Authentication
Access control
Certification
Which of the following members of a class can be handled only from within the class?
Public members
Protected members
Secured members
Private members
Which members are accessible from outside the class?
Public members
Protected members
Secured members
Private members
The members that are accessible from within the class and are also available to its sub classes is called
Public members
Protected members
Secured members
Private members
The part of a program that can see or use the variables are called
Scope
Parameter
Function
Indentation
Which of the following refers to the addresses to an object in memory?
Functions
Indentation
Variables
Operators
How many variables can be mapped to the same instance?
2
3
4
Multiple
Which of the following keeps track of all these mappings with namespaces?
Programming languages
Application software
System software
MySQL
How the names are mapped with objects in programming language?
name == object
name:: object
name:= object
object:= name
The order in which variables have to be mapped to the object in order to obtain the value is called
Rule
Syntax
Scope
Hierarchy
Which of the following rule is used to decide the order in which the scopes are to be searched for scope resolution?
LEGB
LGEB
LBEG
LGBE
Write the below interns of hierarchy (highest to lowest)?
(1) Reversed names in built in functions
(2) Defined inside function
(3) Defined inside enclosing function
(4) Defined at the uppermost level
3,2,1,4
1,4,2,3
2,3, 1,4
2,3,4, 1
How many types of variable scope are there?
2
4
3
6
Which of the following is not a variable scope?
Global
Enclosed
List
Built-in
Choose the type of scope for a variable '9! defined in the following program.
Disp ( ):
a:=7
Print a
Disp ( )
Global
Enclosed
Local
Built-in
A variable which is declared outside all the functions in a program is known as
Local
Enclosed
Extern
Global
Which of the following variable can be accessed inside or outside of all the functions in a program?
Local
Global
Enclosed
Built-in
What is the output of the statement in the following program?
X:=10
Disp ( ):
a:=7
print a
Disp ( ) :
Print a
710
107
7
10
Which of the following can ease the job of programming and debugging the program?
Statements
Interaction
Modules
Scopes
Which of the following programming enables programmers to divide up the work and retry pieces of the program independently?
Modular Programming
Procedural Programming
Object Oriented Programming
Structural Programming
The example of modules are
Procedures
Subroutines
Functions
All of these
Which of the following contain instructions, processing logic and data?
Scopes
Modules
Indentation
Access control
The following are the type of variable scopes Find the odd one out
Local
Enclosed
Global
Protected
Which of the following members of a class are denied access from outside the class?
Private
Protected
Public
Enclosed
Which of the following is not a classical object oriented language
C++
Java
Python
C
Which of the following keywords are not used to control the access to class members?
Public
Protected
Public
Global
How many access control keywords are there?
2
3
4
6
Find the odd man out
Public
Local
Protected
Private
The arrangement of private instance variables and public methods ensure the principle of
Inheritance
Polymorphism
Encapsulation
Abstraction
Which of the following members of a class are accessible from within the class and available to its subclass?
Private
Protected
Public
All of these
By default, the Python. class members are
Private
Protected
Global
Public
By default, the C++ and Java class members are
Private
Protected
Public
Local
Programs are composed of one or more independently developed
Access control
Encapsulatio
Modules
Members of a class
Scope refers to the visibility of___________.
Variables
Parameters
Functions
All of these
Fill up the blank in assign a variable with________to an object.
=
! =
: =
= =
The duration for which a variable is alive is called its_______
End time
Life time
Scope time
Visible time
The scope of a_______ is that part of the code where it is visible
Keyword
Variable
Function
Operator
A Function always first look up for a variable name in its______ scope
Local
Enclosed
Global
Built-in
The inner function can access the variable of the outer function. This is called________scope.
Local
Function
Enclosed
Global
______can be separately compiled and stored in a library
Characteristics
Syntax
Modules
none of these
In Object Oriented Programming Language security is implanted through_______
Access modifiers
Access modules
Access variables
Keywords
___________is a selective restriction of access to data in a program?
Control variable
System authentication
Access control
Module
_________members of the class are accessible from outside the class
Private
Privated
Public
All of these