0% found this document useful (0 votes)
25 views14 pages

Cs 508 Mines Mcqs Midterm

The document contains a set of practice multiple choice questions for a midterm exam on programming language concepts. It includes 10 questions on topics like objectives of learning new languages, computer architecture influence on language design, properties of languages like orthogonality and readability. Another 10 questions are provided later covering additional topics in language concepts.

Uploaded by

nimraashiq031
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views14 pages

Cs 508 Mines Mcqs Midterm

The document contains a set of practice multiple choice questions for a midterm exam on programming language concepts. It includes 10 questions on topics like objectives of learning new languages, computer architecture influence on language design, properties of languages like orthogonality and readability. Another 10 questions are provided later covering additional topics in language concepts.

Uploaded by

nimraashiq031
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

Midterm mcqs for fall 2013

by
Libriansmine

Question # 1 of 10 ( Start time: 11:40:38 PM ) Total Marks: 1


Which of the following is an incorrect option from the following statements regarding
‘objectives of learning new languages ’?
Select correct option:
Help to compare different languages.
Help in transition from one language to other language.
Help in understanding the language pirvacy policy.
Help to choose a language for development of a certain application.

Question # 2 of 10 ( Start time: 11:41:23 PM ) Total Marks: 1


Computer architecture has a major influence on the design of programming language.
Select correct option:
True
False

Question # 3 of 10 ( Start time: 11:42:17 PM ) Total Marks: 1


A language that is more orthogonal is usually more _________.
Select correct option:
Readable
Writable
Portable
Reliable
Question # 4 of 10 ( Start time: 11:43:10 PM ) Total Marks: 1
The variable name has profound effect on _______________.
Select correct option:
Readability
Writability
Orthogonality
Portability

Question # 5 of 10 ( Start time: 11:44:29 PM ) Total Marks: 1


Following factors influences a portable language design EXCEPT
Select correct option:
Computer architecture
Readability
Programmer’s time
Windows XP

Question # 6 of 10 ( Start time: 11:45:29 PM ) Total Marks: 1


In SONOBOL TABLES can be used in a manner similar to _______.
Select correct option:
Array
Pointers
Queue
Struct

Question # 7 of 10 ( Start time: 11:46:26 PM ) Total Marks: 1


Programming Language is basically a tool for instructing a computer to perform specified
set of task.
Select correct option:
True
False

Question # 8 of 10 ( Start time: 11:46:53 PM ) Total Marks: 1


Initial version of SONOBOL only supports __________ and string.
Select correct option:
Digits
Exponential Numbers
Real Numbers
Integer

Question # 9 of 10 ( Start time: 11:47:42 PM ) Total Marks: 1


COBOL is mainly designed for _______.
Select correct option:
Scientific experiments
Business application
AI applications
Publishing and writing algorithm

Question # 10 of 10 ( Start time: 11:48:43 PM ) Total Marks: 1


Following are imperative languages EXCEPT
Select correct option:
LISP
C
FORTRAN
PASCAL
Question # 1 of 10 ( Start time: 07:16:24 PM ) Total Marks: 1
Binary operator in SONOBOL must have at least ________ spaces on both sides.
Select correct option:
2
1
3
5

Question # 2 of 10 ( Start time: 07:16:55 PM ) Total Marks: 1


“Everything for everybody” was the motive of the language
Select correct option:
COBOL
LISP
PL/1
JAVA

Question # 3 of 10 ( Start time: 07:17:23 PM ) Total Marks: 1


_______ was the first object oriented language.
Select correct option:
COBOL
LISP
JAVA
SIMULA

Question # 4 of 10 ( Start time: 07:18:11 PM ) Total Marks: 1


COBOL was the first language that brings the concept of __________.
Select correct option:
Records
Structure
Object
Variable

Question # 5 of 10 ( Start time: 07:19:21 PM ) Total Marks: 1


_____ are a type of Aliasing.
Select correct option:
Pointers
Parameters
Arrays
Linked List

Question # 6 of 10 ( Start time: 07:20:15 PM ) Total Marks: 1


A space is used as _____ for concatenation.
Select correct option:
Variable
String
Data Type
Operator

Question # 7 of 10 ( Start time: 07:20:30 PM ) Total Marks: 1


Following are some of the reasons for studying concepts related to different programming
languages EXCEPT
Select correct option:
Increased ability to learn new languages
Increased capability to design communication links
Increased ability to design new languages
Increased capacity to express programming concepts

Question # 8 of 10 ( Start time: 07:21:26 PM ) Total Marks: 1


COBOL is mainly designed for _______.
Select correct option:
Scientific experiments
Business application
AI applications
Publishing and writing algorithm

Question # 9 of 10 ( Start time: 07:21:35 PM ) Total Marks: 1


The space operator in SNOBOL has _____ precedence than arithmetic operators.
Select correct option:
Lower
Higher

Question # 10 of 10 ( Start time: 07:21:52 PM ) Total Marks: 1


Following are object oriented programming languages EXCEPT
Select correct option:
C++
JAVA
LISP
C#

Question # 1 of 10 ( Start time: 07:22:45 PM ) Total Marks: 1


First electronic computer was _________
Select correct option:
ENIAC
Baggage Analytical Engine
Intel 386
IBM x86

Question # 2 of 10 ( Start time: 07:23:48 PM ) Total Marks: 1


SNOBOL was designed for ___________ purpose.
Select correct option:
String manipulation
AI
Business
Scientific

Question # 4 of 10 ( Start time: 07:25:24 PM ) Total Marks: 1


First language that provided the concept of Pointer data type was _______.
Select correct option:
COBOL
LISP
PL/1
JAVA

Question # 5 of 10 ( Start time: 07:25:54 PM ) Total Marks: 1


In SONOBOL can the size of the array be determined at run time.
Select correct option:
Yes
No

Question # 7 of 10 ( Start time: 07:27:28 PM ) Total Marks: 1


SIZE function in SONOBOL language is used to return the size of _________
Select correct option:
String
Operator
Variable
Keyword

Question # 9 of 10 ( Start time: 07:29:11 PM ) Total Marks: 1


PROLOG represent _______________ paradigm.
Select correct option:
Declarative
Formal
Functional
Algorithmic

Question # 10 of 10 ( Start time: 07:29:53 PM ) Total Marks: 1


SONOBOL is case _______
Select correct option:
Sensitive
In- Sensitive
Super-Sensitive
Not- Sensitive

Question # 1 of 10 ( Start time: 07:33:52 PM ) Total Marks: 1


If a language provides a feature of referencing a variable in more than one way then we say that
the language provides _________.
Select correct option:
Aliasing
Data Mining
Orthogonality
Reliability

sec(s)
Question # 2 of 10 ( Start time: 07:35:07 PM ) Total Marks: 1
For immediate value assignment ______ sign is used.
Select correct option:
%
&
$
*
Question # 6 of 10 ( Start time: 07:36:44 PM ) Total Marks: 1
Pattern . Variable Upon successful completion of pattern matching, the substring matched by the
pattern is assigned to the variable as ________
Select correct option:
Value
String
Integer
Real numbers

Question # 10 of 10 ( Start time: 07:38:56 PM ) Total Marks: 1


Indirect referencing in SONOBOL is same as of _____in C.
Select correct option:
Arrays
Pointers
Aliasing
Stack

Question # 1 of 10 ( Start time: 07:40:28 PM ) Total Marks: 1


The declarative language among the following is
Select correct option:
C
PROLOG
PASCAL
C++

Question # 2 of 10 ( Start time: 07:40:58 PM ) Total Marks: 1


A language that is more orthogonal is usually more _________.
Select correct option:
Readable
Writable
Portable
Reliable

Question # 3 of 10 ( Start time: 07:41:46 PM ) Total Marks: 1


Learning the implementation details of a language helps in the efficient use of that language.
Select correct option:
True
False
Question # 4 of 10 ( Start time: 07:41:59 PM ) Total Marks: 1
First language that provided the concept of Pointer data type was _______.
Select correct option:
COBOL
LISP
PL/1
JAVA

Question # 6 of 10 ( Start time: 07:42:41 PM ) Total Marks: 1


Too much Orthogonality reduces Readability.
Select correct option:
True
False

Question # 10 of 10 ( Start time: 07:45:24 PM ) Total Marks: 1


In SONOBOL 2 spaces can be used, the purpose of 1st space is for _____ and 2nd for
Select correct option:
Pattern matching, String Concatenation
String concatenation, Pattern matching

Question # 2 of 10 ( Start time: 07:55:19 PM ) Total Marks: 1


Too much simplicity in language design can also cause problems.
Select correct option:
True
False

Question # 3 of 10 ( Start time: 07:55:48 PM ) Total Marks: 1


Computer architecture has a major influence on the design of programming language.
Select correct option:
True
False

Question # 4 of 10 ( Start time: 07:56:19 PM ) Total Marks: 1


The more is the Simplicity of a language, the more it will always be readable.
Select correct option:
True
False

Question # 5 of 10 ( Start time: 07:57:15 PM ) Total Marks: 1


_____________ was considered good for describing algorithms.
Select correct option:
FORTRAN
ALGOL
LISP
Ada

Question # 9of 10 ( Start time: 07:59:54 PM) Total Marks: 1


Indirect referencing in SONOBOL is same as of _____in C.
Select correct option:
Arrays
Pointers
Aliasing
Stack

Question # 10of 10 ( Start time: 08:01:17 PM) Total Marks: 1


PROLOG represent _______________ paradigm.
Select correct option:
Declarative
Formal
Functional
Algorithmic

Following is the correct structure of a "block" in Ada.


Options

declare -- declare section optional statements begin declarations exception --


exception section optional handlers end;
declare -- declare section optional declarations begin statements exception
exception section optional handlers end;
declare -- declare section optional statements begin declarations handlers --
exception section optional end;
declare -- declare section optional statements begin statement exception -- exception
section optional handlers end;

3)We can have nested procedures in _________ language.


Options
C++
Ada
C
Prolog

4)____ is used to give comments in Ada language


Options

1)/*
2)*/
3)//
4)--

5)Ada is a _____________ language


Options
1)Typed
2)Strongly Typed
3)weakly typed
4)Non typed

7)In LISP, ___________ is the main tool used for iteration.


Options
1)Recursion
2)For Loop
3)While Loop
4Do-While Loop

8)Following statement returns the union of the two list in LISP.


Options
1)>(L1 UNION L2)
2)>(union L1 L2)
3)>Union L1
4)>(L1 union L2)

9)One of the major design goals of Ada was


Options
to make it difficult for developers to make mistakes
to help developers to code the software in lesser time
to help develop an IDE for Ada
to make testers to test Ada application easily
10)In __________, Enumeration type can also be used as indexes in arrays
Options
Ada\
C
C++
Lisp

Question # 1 of 10 ( Start time: 10:36:28 PM ) Total Marks: 1


Block statement in Ada is very different to a block in C.
Select correct option:
True
False

Question # 2 of 10 ( Start time: 10:36:56 PM ) Total Marks: 1


It is always better to find out the mistakes in the code at ________.
Select correct option:
Compile time
Link time
Run time
None of the given options

uestion # 3 of 10 ( Start time: 10:38:04 PM ) Total Marks: 1

Question # 4 of 10 ( Start time: 10:38:30 PM ) Total Marks: 1


___________ represents the class of languages from functional paradigm.
Select correct option:
LISP
PROLOG
Ada
C++

Question # 6 of 10 ( Start time: 10:40:20 PM ) Total Marks: 1


___________ is an important feature of Ada language used in embedded systems and operating
systems. It is used in managing parallel threads of controls.
Select correct option:
Packages
Controls
Tasking
Classes

Question # 8 of 10 ( Start time: 10:41:45 PM ) Total Marks: 1


The __________ of while loop in Ada is same as in C.
Select correct option:
Syntax
Semantics
Algorithm

Question # 9 of 10 ( Start time: 10:42:55 PM ) Total Marks: 1


The main design goals of Ada were EXCEPT
Select correct option:
Program reliability and maintenance
Design language for DoD
Programming is a human activity therefore avoid unintentional mistakes
Designing a portable language

Question # 10 of 10 ( Start time: 10:43:42 PM ) Total Marks: 1


Lists can be constructed with the help of three basic functions which are ___________.
Select correct option:
scheme, common lisp and cons
cons, append and scheme
cons, list and append
list, atoms and append

Question # 3 of 10 ( Start time: 10:44:51 PM ) Total Marks: 1


__________helps in creating types of your own choice even numeric types can be created.
Select correct option:
Ada
LISP
FORTRAN
PROLOG

Question # 4 of 10 ( Start time: 10:45:32 PM ) Total Marks: 1


Two important versions of LISP are _________________.
Select correct option:
Scheme and Atoms
Scheme and Common Lisp
Common Lisp and defacto
List and Common Lisp

Question # 10 of 10 ( Start time: 10:46:18 PM ) Total Marks: 1


Block statement in Ada is very different to a block in C.
Select correct option:
True
False

Question # 1 of 10 ( Start time: 10:47:55 PM ) Total Marks: 1


Following is the correct syntax of ‘for’ statement in Ada.
Select correct option:
for variable in low_value .. high_value loop -- Loop body goes here end loop;
for variable in low_value .. high_value loop -- Loop body goes here end;
begin; for variable in low_value .. high_value loop -- Loop body goes here end loop;
begin loop; for variable in low_value .. high_value loop -- Loop body goes here end loop;

Question # 3 of 10 ( Start time: 10:49:35 PM ) Total Marks: 1


A concept similar to Classes in Ada is called _____.
Select correct option:
Packages
Structures
Controls
Abstract Data type

Question # 5 of 10 ( Start time: 10:50:37 PM ) Total Marks: 1


Indexes of arrays in Ada DO NOT starts from
Select correct option:
0
1
2
3

Question # 9 of 10 ( Start time: 10:53:57 PM ) Total Marks: 1


In LISP, following statement returns the difference of the two lists.
Select correct option:
(Difference L1 L2)
(set-difference L1 L2)
(L1 Difference L2)
(L1 difference L2)

Question # 10 of 10 ( Start time: 10:54:15 PM ) Total Marks: 1

Question # 2 of 10 ( Start time: 10:54:47 PM ) Total Marks: 1


Ada DO NOT support post test loop like do-while loop.
Select correct option:
True
False

___________
A _____________ program has two types of elements: atoms and lists.
Select correct option:
LISP
PROLOG
Ada
C++

You might also like