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
-
Java programming is derived from C++.
-
The compiler is identical to a C++ compiler.
-
The APIs do all the work.
-
The Java Virtual Machine(JVM) interprets the program for the native operating system.
D
Correct answer
Explanation
Java achieves platform independence through the Java Virtual Machine (JVM). The JVM interprets compiled bytecode for the specific native operating system, allowing the same Java program to run anywhere a JVM is available. This architecture-neutral design separates the compilation process from the execution platform.
-
Java programming is derived from C++.
-
The Java Virtual Machine(JVM) interprets the program for the native operating system.
-
The compiler is identical to a C++ compiler.
-
The APIs do all the work.
B
Correct answer
Explanation
Java's platform independence comes from the JVM. Java source code compiles to bytecode, which the JVM interprets or compiles to native machine code for each specific platform. This abstraction layer is what enables 'write once, run anywhere'. Option A is incorrect - C++ is platform-dependent. Option C is wrong - Java compilers are not identical to C++ compilers. Option D is false - APIs alone don't provide platform independence.
-
a low-level programming language.
-
a scripting language precompiled in the browser.
-
a compiled scripting language.
-
an object-oriented scripting language.
D
Correct answer
Explanation
JavaScript is an object-oriented scripting language that runs in browsers. It's not low-level (A is wrong), not precompiled (B is wrong - it's interpreted), and not compiled (C is wrong). JavaScript supports objects, prototypes, and classes.
-
VBScript
-
JavaScript
-
Perl and C
-
Java
C
Correct answer
Explanation
PHP syntax is heavily influenced by C, Java, and Perl. Its control structures, variable sigils (like Perl's $), and basic block structures closely mirror Perl and C. JavaScript, Java, and VBScript are less direct syntactic ancestors despite some shared programming concepts.
-
a low-level programming language.
-
a compiled scripting language.
-
an object-oriented scripting language.
-
a scripting language precompiled in the browser.
D
Correct answer
Explanation
JavaScript is interpreted by the browser at runtime, making it a scripting language that's precompiled in the browser. Options A and B are incorrect as JavaScript is not low-level or compiled, and option C is wrong as while it has some object-oriented features, it's primarily a scripting language.
-
Control Business-Oriented Language
-
Common Business-Object Language
-
Control Business-Object Language
-
Common Business-Oriented Language
D
Correct answer
Explanation
COBOL stands for Common Business-Oriented Language, a programming language designed for business applications. Option D is correct - it accurately expands the acronym. Options A, B, and C provide incorrect combinations of words that don't represent the actual meaning of COBOL.
-
Virtual Binary Language
-
Video Basic
-
Visual Basic
-
Virtual Basic
C
Correct answer
Explanation
VB stands for Visual Basic, which is a programming language developed by Microsoft. Option A is incorrect as VB is not related to 'Binary'. Option B is wrong because VB is not called 'Video Basic'. Option D is incorrect as it uses 'Virtual' instead of 'Visual'. The correct answer is C.
-
Large Progressive Proffesional
-
List Processing Programming
-
Large Processing Programming
-
List Progressive Programming
B
Correct answer
Explanation
LISP stands for List Processing Programming, a programming language designed for list processing. Option A is incorrect because it uses 'Large' and 'Professional' instead of 'List' and 'Processing'. Option C is wrong because it uses 'Large' instead of 'List'. Option D is incorrect as it uses 'Progressive' instead of 'Processing'. The correct answer is B.
-
Practical Extraction and Recovery Language
-
Proffesional Extraction and Recovery Language
-
Proffesional Extraction and Report Language
-
Practical Extraction and Report Language
D
Correct answer
Explanation
Perl stands for Practical Extraction and Report Language. Option A is incorrect because it uses 'Recovery' instead of 'Report'. Option B is wrong as it uses 'Professional' instead of 'Practical'. Option C is incorrect because it uses 'Professional' instead of 'Practical'. The correct answer is D.
-
StriNgent Object symBOlic Language
-
Software Object symBOlic Language
-
Software Oriented symBOlic Language
-
StriNgent Oriented symBOlic Language
D
Correct answer
Explanation
SNOBOL stands for StriNgent Oriented symBOlic Language, a string processing language. Option A is incorrect as it uses 'Object' instead of 'Oriented'. Option B is wrong because it uses 'Object' instead of 'Oriented'. Option C is incorrect as it uses 'Software' instead of 'StriNgent'. The correct answer is D.
-
ildasm
-
clr
-
ilasm
-
All the above
C
Correct answer
Explanation
IL (Intermediate Language) code can be assembled into executable code using the IL Assembler (ilasm.exe). The ildasm tool is the IL Disassembler (converts assemblies to IL text), and CLR is the runtime environment. ilasm is the correct tool for assembling IL code into executable format.
-
C,C++
-
Active X,Java
-
Dotnet
-
Options 1 and 3
-
Options 1 and 2
E
Correct answer
Explanation
Python integrates with C/C++ through the Python/C API and extensions like ctypes/pybind11. It integrates with Java via Jython (Python implementation on JVM), and with ActiveX/COM on Windows via pywin32. .NET integration exists through IronPython but is less commonly used in standard Python environments.
-
Fixing mistakes in programs is slow
-
It does not have debugging features built-in
-
Python in interpreted language can be tested as soon as it is wriiten,without waiting for its code to compile
-
It doesn't provide interface to major Databases
-
It has less text manipulation feature
C
Correct answer
Explanation
As an interpreted language, Python code can be executed immediately without compilation - you can test code as soon as you write it. Python includes debugging tools like pdb, has extensive text manipulation capabilities (string methods, regex via re module), and provides database interfaces (DB-API).
D
Correct answer
Explanation
Dojo is written in JavaScript. It's a pure JavaScript framework/toolkit that runs in the browser. While it can interact with server-side technologies and can be used in various development environments, the core Dojo toolkit itself is implemented in JavaScript.
B
Correct answer
Explanation
Oracle database is primarily developed in C programming language. The core database engine, memory management, and low-level system interfaces are written in C for portability and performance. While components may use other languages, C remains the foundational language for Oracle's development.