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

Multiple choice technology
  1. document.appletname.getGridObject ().getCellValue (row, column)

  2. document.appletname.getValue (column, row)

  3. document.appletname.getValue (row, column)

  4. none of the above

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

iCommand applets expose values through the getValue(column, row) method in JavaScript. The parameter order is column first, then row index - this is a specific API convention in MII applets. Option B shows the correct syntax.

Multiple choice technology web technology
  1. Compiler Language Runtime

  2. Common Language Runtime

  3. Common Language Running Time

  4. Compiler Language Running Time

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

CLR stands for Common Language Runtime, the execution environment for .NET applications. It manages memory, handles exceptions, and provides core services for running managed code. This is a fundamental .NET framework concept.

Multiple choice technology web technology
  1. Java

  2. C#.Net

  3. ASP

  4. MSIL

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

MSIL (Microsoft Intermediate Language) is the intermediate language in .NET. When you compile .NET code, it's converted to MSIL, which is then converted to native machine code by the JIT compiler at runtime. This allows .NET code to be language-agnostic.

Multiple choice technology web 2.0
  1. When the developer packages the application

  2. When the application loads

  3. The first time it is called

  4. When the application is installed

  5. Each time it is called

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

JIT (Just-In-Time) compilation occurs on-demand - when a method is first invoked at runtime. The method is converted from IL to native code immediately before its first execution, then cached for subsequent calls. This is the core 'just-in-time' concept - compiling right when it's needed.

Multiple choice technology web 2.0
  1. The Common Language Run-time compiles source code to MSIL code.

  2. The C# and VB.NET compilers compile source code to native code

  3. Code compiled in one .NET language can interact with code compiled in a different .NET language

  4. The CLR does NOT implement a Common Type System

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

The CLR enables language interoperability in .NET by allowing code compiled in one .NET language (like C#) to interact with code compiled in another .NET language (like VB.NET). This is possible because all .NET compilers compile to MSIL (Microsoft Intermediate Language), which the CLR executes, and the CLR implements a Common Type System (CTS) ensuring type compatibility across languages.

Multiple choice technology web 2.0
  1. Windows GUI application

  2. Distributed COM

  3. Windows Service

  4. Web Service

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

Web Services are designed to support interoperable machine-to-machine interaction over a network using standard protocols like HTTP and exchanging payloads in XML formats (such as SOAP). Windows GUI apps, Windows Services, and DCOM do not inherently fit this design pattern.

Multiple choice technology programming languages
  1. Conventional Language Runtime

  2. Clarified Language Runtime

  3. Common Language Runtime

  4. Clear Language Runtime

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

CLR stands for Common Language Runtime, which is the virtual machine component of Microsoft's .NET framework. It manages program execution and provides services like memory management, security, garbage collection, and exception handling. The 'Common' signifies that multiple languages (C#, VB.NET, F#) can all compile to IL code that runs on the same runtime. Options A, B, and D are incorrect expansions of the acronym.

Multiple choice technology mainframe
  1. STORAGE

  2. DATA

  3. MAP

  4. LINKAGE

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

The LINKAGE SECTION in a COBOL program is used specifically in called (sub) programs to define data items that will receive parameters passed from the calling program. It 'links' or maps the calling program's data to the called program's working storage, enabling parameter passing between programs.

Multiple choice technology web technology
  1. Account.Username

  2. User.Name

  3. Page.Username

  4. Environment.Username

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

Environment.Username retrieves the Windows identity account name under which the current thread is executing. For ASP.NET applications, this returns the application pool identity (such as NETWORK SERVICE, IIS_APPPOOL, or a custom service account) configured in IIS.

Multiple choice technology web technology
  1. Http-Post

  2. Http-Get

  3. SOAP

  4. All the above

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

ASP.NET Web Services support multiple protocols for communication. HTTP-GET and HTTP-POST are simpler protocols for basic method invocations, while SOAP provides a robust, standards-based protocol with envelope formatting and WS-* extensions. The service can be configured to expose endpoints via any or all of these protocols simultaneously.

Multiple choice technology web technology
  1. Request.ClientAddress

  2. Request.UserHostAddress

  3. Request.IPAddress

  4. Request.Client.IPAddress

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The Request.UserHostAddress property in ASP.NET returns the IP address of the client making the request. This is the standard way to retrieve the client's IP in both Web Forms and MVC. The other property names shown do not exist in the Request object.

Multiple choice technology testing
  1. 4GL

  2. 4 Test Script

  3. VB

  4. VBScript

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

QuickTest Professional (QTP), now known as Unified Functional Testing (UFT), uses VBScript as its scripting language. VBScript is a lightweight, interpreted scripting language based on Visual Basic that allows testers to write automated test scripts with programming constructs like loops, conditions, and functions.

Multiple choice technology mainframe
  1. Section

  2. Paragraph

  3. Modules

  4. Division

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

COBOL programs are hierarchically structured with four divisions (Identification, Environment, Data, Procedure), which contain sections, and sections contain paragraphs. 'Modules' is not a standard COBOL structural component - this term is used in other programming languages but not in COBOL's hierarchy.

Multiple choice technology mainframe
  1. True

  2. False

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

REDEFINES and OCCURS cannot both be specified at the same level number in a COBOL data description entry. REDEFINES must be at the same level as the item being redefined, while OCCURS creates a table/array. To use both, you would typically use REDEFINES at one level and have OCCURS in a subordinate level within the redefined item.