Computer Knowledge
Programming Languages and Compilers
1,170 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
-
objects
-
classes
-
Union
-
functions
-
operators
D
Correct answer
Explanation
In a structure oriented language a program is divided into small programs called functions.
C functions are basic building blocks in a program. All C programs are written using functions to improve reusability, understandability and to keep track on them. A large C program is divided into basic building blocks called C function. C function contains set of instructions enclosed by “{}” which performs specific operation in a C program. Actually, Collection of these functions creates a C program.
-
Interpreter
-
Compiler
-
Simulator
-
Commander
-
_
B
Correct answer
Explanation
It is a software program that converts a complete software program written in a high-level language into machine language.
-
cobalt
-
aluminium
-
language
-
None of these
-
Cobalt
-
Mysql
-
AI
-
All of the above
C
Correct answer
Explanation
Robotics is fundamentally based on Artificial Intelligence (AI), which enables robots to perceive, process information, and make autonomous decisions. While robotics uses various technologies, AI provides the cognitive framework that allows machines to perform complex tasks. Cobalt is a material, MySQL is a database system, and 'All of the above' is incorrect since only AI is the foundational field.
-
PHP
-
Java
-
C#
-
Ruby
-
None of the above
E
Correct answer
Explanation
All are the server side scripting languages.
-
Binary
-
Decimal
-
Octal
-
Hexadecimal
-
English
A
Correct answer
Explanation
Computer system used a binary language because binary is a low level language.
Binary base = 2
-
Unified Modeling Language
-
Framework
-
Use case
-
Conceptualization
-
Software development methodology
A
Correct answer
Explanation
Unified Modeling Language is the graphical modeling language that provides us with syntax for describing the major elements of software systems.
-
Debugger
-
Editor
-
Spooler
-
All of the above
C
Correct answer
Explanation
Spooler is not a utility.
-
Object Based Language
-
Structured Programming Language
-
Procedural Language
-
Object Oriented Language
D
Correct answer
Explanation
C++ is a multi-paradigm language that supports object-oriented programming (classes, inheritance, polymorphism, encapsulation). While it also supports procedural and generic programming, its classification as an Object-Oriented Language is correct because it provides complete OOP features including classes, objects, inheritance, and virtual functions.
A
Correct answer
Explanation
Pascal is a traditional procedural programming language without native support for OOP features like classes, inheritance, or polymorphism. C++, C#, and Java were designed as object-oriented languages from their inception.
C
Correct answer
Explanation
UML (Unified Modeling Language) is a language for modeling, visualizing, specifying, constructuing and documenting the artifacts of a software intensive 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
-
None of these
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.
-
Lexical analysis
-
Syntax analysis
-
Intermediate code
-
Code optimization
A
Correct answer
Explanation
Lexical analyzer reads the source program one character at a time, carving the source program into a sequence of atomic units called tokens.
-
Lexical analysis
-
Syntax analysis
-
Intermediate code
-
Code generation
B
Correct answer
Explanation
Syntax analyzer phase imposes on a token a tree like structure called as parse tree.
-
Macro expansion
-
Macro processor
-
Macro
-
Macro parameters
C
Correct answer
Explanation
Macro is a unit of specification for program generation through expansion.