Ada: The First Computer Programmer: 16 MCQs

All 16 multiple-choice questions from this kit, free and with no sign-up.

Warm-up · 5 questions

Q1. Ada was commissioned by which organisation?

Beginner
A The International Organization for Standardization
B The United States Department of Defense
C The European Space Agency
D The British Computer Society

Answers and explanations are in the Veda app.

Q2. Ada is named after which person?

Beginner
A Grace Hopper
B Charles Babbage
C Ada Lovelace
D Jean Ichbiah

Answers and explanations are in the Veda app.

Q3. In which year was Ada standardised by ANSI, giving Ada 83?

Beginner
A 1995
B 1975
C 2005
D 1983

Answers and explanations are in the Veda app.

Q4. Which feature is built into Ada for expressing parallel activities?

Beginner
A The thread library
B The task construct
C The goroutine
D The async keyword

Answers and explanations are in the Veda app.

Q5. Ada was commissioned by the **US Department of Defense** and standardised as **Ada 83**; it is named after **Ada Lovelace**.

Beginner
A True
B False

Answers and explanations are in the Veda app.

Building up · 6 questions

Q6. A team is writing software for a fly-by-wire flight control system where a single fault could be catastrophic. Which language characteristic of Ada is most directly relevant to this need?

Intermediate
A Its strong typing and runtime checks turn many errors into compile-time or controlled failures.
B It supports object-oriented programming since Ada 95.
C It has an active ISO standard.
D Its English-like keywords make programs shorter.

Answers and explanations are in the Veda app.

Q7. Why does Ada use distinct numeric types such as Metres and Seconds?

Intermediate
A To save memory by using smaller representations.
B To speed up floating-point arithmetic.
C To allow automatic conversion between any numeric types.
D To make unit-mixing errors compile-time failures.

Answers and explanations are in the Veda app.

Q8. What is the role of a package specification in Ada?

Intermediate
A It holds the implementation details hidden from clients.
B It stores the compiled object code.
C It defines the runtime checks for the package.
D It is the public interface that clients can see.

Answers and explanations are in the Veda app.

Q9. Which Ada revision introduced contracts such as preconditions and postconditions written into the code?

Intermediate
A Ada 2012
B Ada 83
C Ada 95
D Ada 2005

Answers and explanations are in the Veda app.

Q10. A student claims that Ada is obsolete because it was designed in the 1970s. Which fact best refutes this claim?

Intermediate
A Ada 83 was standardised by ANSI.
B Ada has an active ISO standard and is still chosen for new safety-critical projects.
C Ada was named after Ada Lovelace.
D Ada favours readability over terseness.

Answers and explanations are in the Veda app.

Q11. In Ada, what happens when a program attempts to access an array element outside its declared bounds?

Intermediate
A The program silently returns a default value.
B A runtime check raises an exception instead of corrupting memory.
C The compiler rejects the program before it runs.
D The array automatically resizes to fit the index.

Answers and explanations are in the Veda app.

Topper level · 5 questions

Q12. Which pair of design goals most clearly explains why Ada uses English-like keywords such as begin, end, is and then?

Advanced
A Ease of automatic translation to other languages
B Readability and reviewability of safety-critical code
C Compatibility with older assembly languages
D Faster compilation and smaller binaries

Answers and explanations are in the Veda app.

Q13. A developer wants to hide implementation details from client code while still exposing a stable interface. Which Ada mechanism directly provides this?

Advanced
A Using the task construct for concurrency
B Adding preconditions and postconditions
C Declaring all variables as access types
D Splitting a package into a specification and a body

Answers and explanations are in the Veda app.

Q14. Consider this Ada declaration: ```ada type Metres is new Float; type Seconds is new Float; ``` A programmer then writes an expression that adds a Metres value to a Seconds value. What is the most likely outcome?

Advanced
A The program compiles and runs, producing a value in Metres.
B The compiler automatically converts Seconds to Metres.
C The program compiles but raises a runtime exception.
D The compiler rejects the expression as a type error.

Answers and explanations are in the Veda app.

Q15. Which statement best captures the relationship between Ada's revisions (Ada 83, 95, 2005, 2012) and backward compatibility?

Advanced
A Each revision maintained backward compatibility, so old code still compiles.
B Each revision broke compatibility to allow cleaner syntax.
C Only Ada 2012 maintained backward compatibility with Ada 83.
D Backward compatibility was never a goal of the Ada standards.

Answers and explanations are in the Veda app.

Q16. Given the following Ada function declaration that includes preconditions and postconditions, analyze the implications of the conditions on the function's usability and safety: ```ada function Sqrt (X : Float) return Float with Pre => X >= 0.0, Post => Sqrt'Result >= 0.0; ``` What is the most significant benefit of using such contracts in Ada?

Advanced
A They ensure that the function can be used without any input validation.
B They allow for more concise code without runtime checks.
C They provide a formal guarantee of correctness for the function's behavior.
D They eliminate the need for documentation since the code is self-explanatory.

Answers and explanations are in the Veda app.

Make your own

Your notes can be a kit like these

Every kit here was made from real study material. Point Veda at a chapter, a PDF, a photo or a link and get notes, flashcards, practice MCQs, games and a scored test — free to start, in more than 40 languages.

  • Chapter notes
  • Flashcards
  • Practice MCQs
  • Scored tests
  • Paper Solver

Get Veda free See what students get

Free to start · Android app and web · More than 40 languages