MCQ Bank
What will be the result of following function call in LISP? >(/ 7.0 2)
- A) 9.0
- B) 3.5
- C) 7/2
- D) 7.02
In Ada, tagged type definition is performed in a _______.
- A) Record
- B) Template
- C) Structure
- D) Package
___________ is the Equality Operator in ADA.
- A) =:
- B) :=
- C) ==
- D) =
The correct way to declare an 'access' type in Ada is:
- A) type ref_type:= Address;
- B) type ref_type = Address;
- C) type ref_type is access Address;
- D) type ref_type :: Address;
To terminate a simple loop in Ada, which of the following statement is used?
- A) break
- B) end
- C) exit
- D) finish
Consider the following two statements written in Ada: type Months is (January, February, March, April, May, June, July); type Monthly_Sales is array(Months) of Float; What is size of array named ‘Monthly_Sales’?
- A) 7
- B) 8
- C) 2
- D) 3
Which of the following statement of LISP creates an array of size 5?
- A) (make linear-array (5))
- B) (setf (make-array ‘(5)))
- C) (setf linear-array (make-array ‘(5)))
- D) (setq linear-array (array ‘(5)))
Disjunction in Prolog is through ________and conjunction is through _____.
- A) OR, Dot(.)
- B) Coma (,), OR
- C) OR, coma (,)
- D) Dot(.) , OR
Each axiom in PROLOG program is:
- A) an object
- B) a function
- C) Conditional statement
- D) Horn clause
LISP was the first programming language that introduced the concept of ________.
- A) Pointers
- B) Dynamic typing
- C) Trees
- D) Arrays
Expert system___________ provide a structure to design expert system.
- A) Techniques
- B) Shells
- C) Mechanism
- D) Lists
A PROLOG program can have:
- A) Multiple Goals
- B) Even number of goals
- C) Odd number of goals
- D) Exactly one instance of a goal
The correct way to write Goal for following statement in PROLOG is _________________. "Which medicine relieves in diarrhea?"
- A) M (relieves, diarrhea).
- B) M (diarrhea, relieves).
- C) diarrhea (relieves, M).
- D) relieves (M, diarrhea).
The first programming language to support Recursion was ________.
- A) FORTRAN
- B) LISP
- C) ADA
- D) COBOL
Following statement in PROLOG is considered as ______________________. "unsuitable_for(Person, Drug) :- aggravates(Drug, Condition), suffers_from(Person, Condition)."
- A) Goal
- B) Variable
- C) Rule
- D) Fact
Problem solving in PROLOG is achieved by using:
- A) Streams
- B) Facts
- C) Functions
- D) Objects
In Prolog, we specify _______and do not specify _________.
- A) Result , Inputs
- B) Facts, Problem
- C) Result , Outputs
- D) Problem , Solution
A list in PROLOG can have elements of ________ type and size.
- A) Three
- B) Fixed
- C) Arbitrary
- D) Two
The main feature of PROLOG language is its ability to handle and process __________.
- A) Objects
- B) Classes
- C) Functions
- D) Symbols
The basic tool for writing programs in PROLOG is:
- A) Polymorphism
- B) Recursion
- C) Object-Orientation
- D) Inheritance