WITH COMPLETE SOLUTIONS VERIFIED
Event-driven computing paradigm is to
define a set of events and write an event handler for each event
What is the major improvement of structured programming languages over the
earlier programming languages?
Removing Goto statement from the language
What programming language characteristics impact the readability of the
programs written in this language?
Control structures, syntax design, Data Structures
In contrast to Web 1.0, what is the key function of Web 2.0?
Web is the computing platform
What programming paradigm does Fortran belong to?
imperative
Which commands (constructs) do NOT have a loop when expressed in syntax
graphs?
if-then-else
for(<init-expr>; <test-expr>; <increment-espr>){<statements>}
while (condition) do {statements}
How many different identifiers can the following BNF ruleset generate?
,<char> ::= a | b | c |...| x | y | z
<identifier> ::= <char> | <char> <identifier>
more than 26
which of the following cannot be checked by an imperative or object-oriented
compiler?
semantics
Which command will have a loop when expressed in a syntax graph?
switch
If your program was designed to print "Hello World" ten times, but during
execution, it printed eleven times, what type of error is it?
Semantics error
If your application is composed of multiple modules (programs), which of the
following program processing would you recommend?
compilation
What is the main reason of applying two-step translation of high level
programming languages?
one compiler for all machines
What is "func" in this C program example?
#include <stdio.h>
#define func(x, y) (x > y) ? y : x
int main(){
int x = 10;
int y = 9;
, int z = func(x, y);
}
a macro
a final method in Java defines
an in-line function
Macros-Processing in C takes place during which phase?
pre-processing
Converting an integer value 5 to a float number 5.0 takes
more than two machine instructions
Which of the following are correct if a language is strongly typed?
each name in a program has a single type associated with it, type errors are always
reported
Which language will report a compilation error in the following snippet of code?
int i = 3;
double n, j = 3.0;
n = i + j;
Java
Type checking happens during the compilation phase, it reinforces which of the
following structural layers?
contextual
(True or False) Sort orthogonality 1 and sort orthogonality 2 implies
compositional orthogonality
true