JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD
JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD B.Tech III PRINCIPLES OF PROGRAMMING LANGUAGES Previous Question Paper (March - 2021 - R18)
Answer any five questions
All questions carry equal marks
Main
What are the various language evaluation criteria and the characteristics that affect them? Discuss.
Answer
Language evaluation criteria are used to assess the quality of programming languages. The primary criteria include:
- Readability: The ease with which programs can be read and understood. Characteristics affecting this include orthogonality, data types, syntax design, and support for abstraction.
- Writability: The ease with which a language can be used to create programs. It is influenced by expressivity, support for abstraction, and simplicity.
- Reliability: The degree to which a program performs to its specifications under all conditions. Key factors are type checking, exception handling, aliasing, and readability/writability.
- Cost: The total expense of using the language, including training programmers, writing code, compiling, executing, and maintaining software.
Other criteria include portability, generality, and well-definedness.
Explain about various programming domains and their features.
Answer
Programming languages are categorized based on their intended application domains, each requiring specific features:
- Scientific Applications: These require efficient floating-point calculations and array processing. Examples include Fortran and Ada, which emphasize performance and numerical precision.
- Business Applications: These focus on producing reports, decimal arithmetic, and character data handling. COBOL is the classic example, designed for ease of use in data management.
- Artificial Intelligence: These require symbolic manipulation and dynamic memory management. Languages like LISP and Prolog excel here due to their ability to process lists and implement logic-based reasoning.
- Systems Programming: These require high execution efficiency and low-level access to hardware. C and C++ are common, providing features for memory management and direct machine control.
- Web Software: These involve a mix of markup, scripting, and general-purpose languages. They require support for concurrency, security, and dynamic content generation, as seen in JavaScript, PHP, and Java.
Write BNF and EBNF versions of an expression grammar.
Answer
Sign in to view the complete answer paper.
Explain in detail about attribute grammars with examples.
Answer
Sign in to view the complete answer paper.
Distinguish between name type compatibility and structure type compatibility.
Answer
Sign in to view the complete answer paper.
Discuss the design issues of multiple selection constructs.
Answer
Sign in to view the complete answer paper.
What is a short-circuit evaluation? How does operand evaluation order interact with functional side effects?
Answer
Sign in to view the complete answer paper.
Explain the design issues of subprograms and operations.
Answer
Sign in to view the complete answer paper.
Write about parameterized abstract data types with an example in C++.
Answer
Sign in to view the complete answer paper.
What are the language design requirements for a language that supports abstract data types?
Answer
Sign in to view the complete answer paper.
Why were imperative features added to most dialects of LISP? Discuss.
Answer
Sign in to view the complete answer paper.
Explain in detail about exception handling in Ada.
Answer
Sign in to view the complete answer paper.
What are the applications of functional programming? Explain.
Answer
Sign in to view the complete answer paper.
What are the features of Prolog? Discuss the basic elements of Prolog.
Answer
Sign in to view the complete answer paper.
Write the key concepts of scripting languages and explain them.
Answer
Sign in to view the complete answer paper.
Differentiate between procedural abstraction and data abstraction with examples.
Answer
Sign in to view the complete answer paper.