PET 8 Flashcards
The term (1+i)^n, also denoted as (F/
Pi,n) is called:
A. equal-payment-series compound-amount
factor
B. equal-payment-sinking-fund factor
C. single payment compound-amount
factor
D. single payment present-worth factor
C. single payment compound-amount
factor
What is defined as the reduction or fall of the value of an asset due to constant use and passage of time?
A. Depreciation
B. Depletion
C. Deflation
D. Inflation
A. Depreciation
Which of the following type of class
allows only one object of it to be
created?
A. Virtual class
B. Abstract class
C. Singleton class
D. Friend class
C. Singleton class
What will be the output of the program?
#include<stdio.h>
int main()
{
int i=1;
switch(i)
{
printf("Hello\n");
case 1:
printf("Hi\n");
break;
case 2:
printf("\nBye\n");
break;
}
return 0;
}</stdio.h>
A. Hello, Hi
B. Bye
C. Hi
D. Hello, Bye
C. Hi
Which of the following concepts means determining at runtime what method to invoke?
A. Dynamic Typing
B. Dynamic loading
C. Dynamic binding
D. Data hiding
C. Dynamic binding
How many instances of an abstract
class can be created?
A. 13
B. 5
C. 1
D. 0
D. 0
Which of the following concepts
provides facility of using object of one
class inside another class?
A. Inheritance
B. Composition
C. Encapsulation
D. Abstraction
B. Composition
The use of the break statement in a
switch statement is
A. compulsory
B. optional
C. not allowed. It gives an error message
D. to check an error
B. optional
Which of the following concepts means
wrapping up of data and functions
together?
A. Polymorphism
B. Inheritance
C. Abstraction
D. Encapsulation
D. Encapsulation
Which of the following statements is
false?
A. A function is a block of code that performs
a specific task
B. Functions allow programmers to break
large and complex problems into small and
manageable tasks
C. Functions can be called, or invoked,
only once in a program
D. Functions allow programmers to use
existing code to perform common tasks
C. Functions can be called, or invoked,
only once in a program
When you pass a variable_,C++
passes only the contents of the variable
to the receiving function
A. by reference
B. globally
C. locally
D. by value
D. by value
Which of the following statement is
correct?
A. Object is an instance of a class.
B. Object is an instance of data type.
C. Class is an instance of object.
D. Class is an instance of data type.
A. Object is an instance of a class.
A default catch block catches
A. all thrown objects that have been
caught by an earlier catch block
B. any thrown object that has not been
caught by an earlier catch block
C. all thrown objects
D. no thrown objects
A. all thrown objects that have been
caught by an earlier catch block
What will be the output of the program?
#include<stdio.h>
int main()
{
int k, num= 30;
k=(num<10)?100:200;
printf("%d\n", num);
return 0;
}</stdio.h>
A. 100
B. 200
C. 500
D. 30
D. 30
Which of the following is not logical
operator?
A. !!
B. !
C. &&
D. &
D. &
A base class may also be called a
A. child class
B. derived class
C. parent class
D. subclass
C. parent class
A system program that sets up an
executable program in main memory
ready for execution is
A. assembler
B. linker
C. compiler
D. loader
D. loader
How many times the program will print
“IndiaBIX”?
#include<stdio.h>
int main()
{
printf("IndiaBIX");
mainO);
return 0;
}</stdio.h>
A. Till stack overflows
B. Infinite times
C. 65535 times
D. 32767 times
A. Till stack overflows
Understanding the Cartesian coordinate
system will help the beginning drafter
A. control the accuracy of the drawing
B. select a different text style
C. produce a visible grid system
D. choose various line types
A. control the accuracy of the drawing
How many times “engineer” is get
printed?
#include<stdio.h>
int main()
{
int x;
for(x=-1; X<=10; x++)
{
if(x<5)
continue;
else
break;
printf("engineer");
}
return 0;
}</stdio.h>
A. 11 times
B. 10 times
C. Infinite times
D. O times
D. O times
When the minimum and maximum
number of instances of an entity is one,
you know which of the following?
A. Mandatory one
B. Optional one
C. Cannot tell
D. Mandatory many
A. Mandatory one
What will be the output of the program?
#include<stdio.h>
int main()
{
int i=3;
i=i++;
printf("%d\n", i);
return 0;
}</stdio.h>
A. 6
B. 4
C. 5
D. 3
B. 4
A program that converts a high-level
language program to a set of
instructions that can run on a computer
is called a
A. All of these choices
B. Debugger
C. Editor
D. Compiler
D. Compiler
Bug means
A. A difficult syntax error in a program
B. All of these choices
C. Documenting programs using an efficient
documentation tool
D. A logical error in a program
D. A logical error in a program