Why is it good programming style to place the class declaration in a header file (*.h) and the associated code in a source code file (*.cpp).

What will be an ideal response?


This gives use a nice way to organize the code. The *.h file will be included in files that needs to use that class’ object. Also, if we create libraries of our source code, we’d want to have our *.cpp compiled into a library and the *.h would be available as documentation of the class.

Computer Science & Information Technology

You might also like to view...

You can use spreadsheets for simple or complex calculations.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

When an On Close event is triggered and there is no macro attached to the event, Access runs its default On Close macro

Indicate whether the statement is true or false

Computer Science & Information Technology

A Total row in a table can include functions such as Sum, Avg, and Count

Indicate whether the statement is true or false

Computer Science & Information Technology

In a computer forensics investigation, ________ describes the route that evidence takes from the time you find it until the case is closed or goes to court.

A. Policy of separation B. Rules of evidence C. Law of probability D. Chain of custody

Computer Science & Information Technology