Which answer most closely explains what Margaret Hamilton meant by the statement, “It’s like preventative healthcare, but preventative software.”(2 points)

Responses

Preventative software can be used in the medical field to prevent surgical robotic errors. Surgical robotics is a growing field that cannot afford to have errors due to human lives being at stake.
Preventative software can be used in the medical field to prevent surgical robotic errors. Surgical robotics is a growing field that cannot afford to have errors due to human lives being at stake.

Before astronauts can travel to the moon, they need to go through extensive preventative healthcare measures to avoid getting sick while in space. Similarly, software should be used to prevent astronauts from getting sick in space.
Before astronauts can travel to the moon, they need to go through extensive preventative healthcare measures to avoid getting sick while in space. Similarly, software should be used to prevent astronauts from getting sick in space.

While a root canal can be performed by a dentist, there are also steps that could be taken to prevent its necessity. Similarly, there are steps that can be taken to prevent errors and issues due to poorly engineered software.
While a root canal can be performed by a dentist, there are also steps that could be taken to prevent its necessity. Similarly, there are steps that can be taken to prevent errors and issues due to poorly engineered software.
Question 2
Which of the following is the best explanation of a software function?(2 points)
Responses

A function that provides a set of instructions or tasks that a software program performs.
A function that provides a set of instructions or tasks that a software program performs.

A function that creates objects.
A function that creates objects.

A function that sorts items.
A function that sorts items.

A function that performs a mathematical operation.
A function that performs a mathematical operation.
Question 3
Car.Engine.CruiseControl.setCruiseSpeed(55) is an example of a function nested inside an object (CruiseControl), which is nested inside another object (Engine), and nested inside a final object (Car). This is an example of which paradigm?(2 points)
Responses

Object-oriented programming
Object-oriented programming

Automotive programming
Automotive programming

Procedural programming
Procedural programming

Event-driven programming
Event-driven programming
Question 4
Why is it critical for a developer to include well written documentation about what each function in the code does?(2 points)
Responses

So that my programming teacher will be happy.
So that my programming teacher will be happy.

So that other developers at other companies know what code is copyrighted.
So that other developers at other companies know what code is copyrighted.

So that others working on a different part of the overall project are able to write code that interacts with their work.
So that others working on a different part of the overall project are able to write code that interacts with their work.

So that someone who buys the software knows how to use it.
So that someone who buys the software knows how to use it.
Question 5
What is the difference between private and public functions?(2 points)
Responses

Public functions are only available to public sector companies, while private functions have strict copyright laws.
Public functions are only available to public sector companies, while private functions have strict copyright laws.

Private functions are only visible to the developer creating them, while public are listed publicly in a repository for the whole world to see.
Private functions are only visible to the developer creating them, while public are listed publicly in a repository for the whole world to see.

Private and public functions do not have any differences.
Private and public functions do not have any differences.

Private functions are only accessible to functions within the parent object, public functions can be accessed by other objects.
Private functions are only accessible to functions within the parent object, public functions can be accessed by other objects.
Skip to navigation

1 answer

Question 1: The answer that most closely explains what Margaret Hamilton meant by the statement, “It’s like preventative healthcare, but preventative software,” is:

While a root canal can be performed by a dentist, there are also steps that could be taken to prevent its necessity. Similarly, there are steps that can be taken to prevent errors and issues due to poorly engineered software.


Question 2: The best explanation of a software function is:

A function that provides a set of instructions or tasks that a software program performs.


Question 3: The example Car.Engine.CruiseControl.setCruiseSpeed(55) is an example of which paradigm:

Object-oriented programming.


Question 4: It is critical for a developer to include well-written documentation about what each function in the code does:

So that others working on a different part of the overall project are able to write code that interacts with their work.


Question 5: The difference between private and public functions is:

Private functions are only accessible to functions within the parent object, public functions can be accessed by other objects.