Computer Knowledge
Programming Languages and Compilers
2,284 Questions
Programming languages and compilers involve the rules, syntax, and semantics used to write and execute software programs. Key areas include scripting languages, object oriented concepts, and parsing algorithms like top down parsers. Practice these computer science questions to build proficiency for technical and computer knowledge exams.
Object oriented languagesScripting languagesCompilers and parsersProgramming syntax
Programming Languages and Compilers Questions
-
a benchmark program
-
an intrinsic function
-
a data structure
-
none of the above
B
Correct answer
Explanation
Intrinsic functions are built-in functions provided by the programming language environment to perform common tasks, making the language easier to use without requiring the programmer to write them from scratch.
-
Must use a sorted array
-
Requirement of sorted array is expensive when a lot of insertion and deletions are needed
-
There must be a mechanism to access middle element directly
-
Binary search algorithm is not efficient when the data elements are more than 1000
-
Sementics
-
Syntax
-
Keywords
-
Algorithms
-
None of these
C
Correct answer
Explanation
Keywords are the reserved commands in a programming language.
-
NEGATE
-
ADD
-
INCREMENT
-
COMPARE
-
DIVIDE
D
Correct answer
Explanation
COMPARE is a logical instruction for 8085 microprocessor.
-
Interpreter
-
Assembler
-
Compiler
-
All have the same speed.
-
None of these
C
Correct answer
Explanation
Compiler is the fastest high level language to machine level language translator as it converts whole source code at a time and also keeps record of converted lines, so that it can be used in case of repetition.
-
API for developing 32-bit applications
-
text editor for UNIX-based computer systems
-
program that flags suspicious constructs
-
UNIX utility that parses text
-
screen-oriented text editor
B
Correct answer
Explanation
PICO stands for pine composer. It is an easy-to-use text editor for UNIX and UNIX-based system.
-
The UML is a language for visualising.
-
The UML is a language for constructing.
-
The UML is a language for modeling.
-
The UML is a language for documenting.
B
Correct answer
Explanation
This means that it is possible to map from a model in the UML to a programming language such as JAVA, C++ or VB, or even to table in the relational database or the persistent store of an object oriented database.
D
Correct answer
Explanation
Data Manipulation Language - It is used to manipulate the database.
-
Addition of two addresses
-
Multiplication of two addresses
-
Multiplication of an address with a constant
-
Divison of an address with a constant
-
All of the above
E
Correct answer
Explanation
This is the correct choice.
A
Correct answer
Explanation
A contains F0 (in hexadecimal), F0 can be written as 1111 0000 STC(set Carry Flag) CF=1
RRC(Rotate Right ACCUMULATOR with Carry)
Now Rotate the accumulator content to the right with carry thrice
Initial data 1 1111 0000
First Rotation 0 1111 1000
second Rotation 0 0111 1100
Third Rotation 0 0011 1110
In Hexadecimal 0011 1110 is written as 3E
-
Automatic
-
Static
-
Register
-
Union
-
Extern
D
Correct answer
Explanation
Unions are quite similar to the structures in C. Union is also a derived data type as structure. Unions are not a memory storage class.
-
Recognised only by a Turing machine.
-
Context -sensitive.
-
Regular.
-
Unrestricted.
-
Context-free.
E
Correct answer
Explanation
C is a context-free language.
-
C++
-
Java
-
Visual Basic
-
HTML
D
Correct answer
Explanation
HTML (HyperText Markup Language) is the standard language used to create and structure content for web pages.
-
interpreted
-
3rd generation
-
4th generation
-
compiled
D
Correct answer
Explanation
Python is an interpreted language, not a compiled one (like C++).