Chapter 40 Quiz: The Fortran Career
Twenty questions to check that the closing chapter landed — and, in Part D, a last broad sweep across the book. Answer without looking back first; then check the key. Target: 16 / 20. Below 16, re-read the sections flagged in "Topics to review." This is a beginner chapter, so the questions test understanding and honesty, not obscure detail.
Part A — Multiple Choice
Q1. Which set of institutions is correctly described as a major, present-day employer of Fortran programmers? - (a) Social-media companies and mobile-game studios - (b) US Department of Energy national laboratories (Oak Ridge, Livermore, Los Alamos, Argonne, Sandia) - (c) Front-end web-development agencies - (d) None — Fortran is no longer used commercially
Q2. A person holds a PhD in atmospheric science, devises numerical methods, and writes and validates the simulations that answer their research questions. This role is best described as a: - (a) Domain scientist who only runs existing codes - (b) Computational scientist - (c) Front-end engineer - (d) Database administrator
Q3. What is a research software engineer (RSE)? - (a) A scientist who never writes code - (b) A professional who combines software-engineering expertise with research understanding to build and maintain the software research depends on - (c) A hardware technician who repairs supercomputers - (d) A project manager with no technical role
Q4. The "Fortran programmer shortage" is best characterized as: - (a) A precise, audited statistic: exactly 3.2 jobs per qualified applicant - (b) A myth with no basis - (c) A widely reported imbalance between open positions and available people, not a precise statistic - (d) A problem only in the video-game industry
Q5. Which résumé framing presents Fortran most effectively for a scientific-computing role? - (a) "Languages: Fortran" - (b) "Some old Fortran" - (c) "Modern Fortran (2018) for high-performance numerical kernels, wrapped for Python with f2py, parallelized with OpenMP/MPI" - (d) "Fortran (deprecated)"
Q6. Which is the best first contribution to an open-source scientific code for a newcomer? - (a) Rewriting the entire solver in a different language - (b) A small, correct, well-tested change — a doc fix, a missing test, a clearer error message - (c) Nothing until you are an expert - (d) A large untested pull request changing the core physics
Q7. Three forces are given in the chapter as causes of the shortage. Which is not one of them? - (a) Universities largely stopped teaching Fortran - (b) The large validated codes are still running and growing - (c) The original expert authors are retiring - (d) Fortran compilers have stopped being maintained
Q8. Why does the book decline to quote a specific salary figure? - (a) Salaries are secret - (b) Fortran jobs are unpaid - (c) Compensation varies enormously by country, sector, and seniority, so any single number would mislead — and a fabricated one would be worse - (d) The authors do not know what a salary is
Part B — True/False (justify in one sentence)
Q9. True or false: "Fortran runs every supercomputer's operating system." Justify.
Q10. True or false: The ability to navigate and safely modernize a large validated Fortran code is a common skill that most new graduates have. Justify.
Q11. True or false: Putting a LICENSE file in your portfolio repository matters, because code with no
license is legally difficult for others to reuse. Justify.
Q12. True or false: On a résumé, "Fortran" alone communicates the same thing to a hiring manager as "modern Fortran, paired with Python and the HPC toolchain." Justify.
Q13. True or false: The heat-equation solver built across this book is, in kind, the same sort of code (a finite-difference PDE solver) that runs in production weather and CFD codes — differing mainly in scale and validation. Justify.
Part C — Short Answer
Q14. Name the two career-role terms this chapter first-defined, and give the one phrase that distinguishes them (which end of the science↔software spectrum each sits on).
Q15. In one sentence each, describe what a computational scientist and an HPC engineer spend most of their day on.
Q16. Give the four artifacts that turn your solver from "a program in a folder" into a portfolio piece.
Q17. Explain in two sentences why "scarcity is leverage" applies to Fortran skills.
Part D — What Does This Code Print? / Broad Review
Q18. The skills-inventory program (example-01) marks all 8 skills .true.. What are the last two lines
it prints?
Q19. Given this internal-file write, what string ends up in line?
integer :: nx = 128, nsteps = 2000
character(len=80) :: line
write(line, '(a,i0,a,i0,a)') 'grid ', nx, ', ', nsteps, ' steps'
Q20. (Broad review.) In one line each: (i) what is 7/2 for default integers in Fortran, and (ii)
which tool wraps a Fortran routine so Python can call it?
Part E — Applied / Scenario
Q21. A recruiter for a national lab skims your résumé for four seconds. You have two versions of one line: "Languages: Fortran, Python" and "High-performance numerical kernels in modern Fortran (2018), wrapped for Python with f2py, parallelized with OpenMP/MPI." Which version, and what is the one word that best names what the second version signals about you that the first does not?
Q22. True or false, with a reason: "To prove your ability, a first open-source contribution should be a large, ambitious change to a code's core physics." Justify in one sentence.
Q23. You want to put a speedup on your résumé. Which is the honest form? - (a) "Made Fortran code 100× faster" - (b) "Achieved ≈8× speedup on 8 OpenMP threads (one 8-core node), validated against the serial result" - (c) "Fortran is 100× faster than Python" - (d) Omit it — speedups can never be stated honestly
Q24. The Laplacian snippet (example-03) is applied to a $3\times3$ field whose top row is $100$ and the
rest $0$, with $dx = dy = 1$. What single value appears at the center of the printed laplacian(u) array,
and why is every other entry $0.00$?
Answer Key
| Q | Answer | One-line rationale |
|---|---|---|
| 1 | b | The DOE national labs are a dense, present-day concentration of Fortran work (§40.1). |
| 2 | b | Devising methods and writing/validating simulations as science is the computational scientist (§40.2). |
| 3 | b | The RSE combines software-engineering skill with research understanding (§40.2, definition). |
| 4 | c | Widely reported imbalance, not a precise audited statistic (§40.3). |
| 5 | c | Frames Fortran as modern HPC and pairs it with Python + parallelism (§40.4). |
| 6 | b | Small, correct, well-tested changes earn the standing for bigger ones (§40.5). |
| 7 | d | Compilers are actively maintained (gfortran, ifx, LFortran); that is not a cause. |
| 8 | c | Compensation varies too much for one honest number; a fabricated one is worse (§40.3). |
| 9 | False | The OS is Linux (written in C); the science on the machine is very often Fortran (§40.1; Ch 1). |
| 10 | False | It is rare — universities stopped teaching it — which is exactly the shortage/leverage (§40.3). |
| 11 | True | Unlicensed code is legally unsafe for others to reuse; a LICENSE signals you understand this (Checkpoint). |
| 12 | False | Alone it reads "legacy"; paired it reads "HPC engineer" — same skill, better framing (§40.4). |
| 13 | True | Both are finite-difference PDE solvers; the difference is scale and validation (§40.1, §40.5). |
| 14 | — | computational scientist (science end) and research software engineer (software end) (§40.2). |
| 15 | — | Computational scientist: methods + the science; HPC engineer: performance, parallelism, architecture (§40.2). |
| 16 | — | README, LICENSE, one visualization figure, one-paragraph abstract (Project Checkpoint). |
| 17 | — | The skill is rare and badly needed; rarity + need = leverage over jobs, pay, and trust (§40.3). |
| 18 | — | you can do 8 of 8 then readiness: 100.0% (example-01 output). |
| 19 | — | grid 128, 2000 steps (i0 prints integers with no leading blanks). |
| 20 | — | (i) 3 (integer division truncates, Ch 3); (ii) f2py (Ch 15). |
| 21 | second | The word is "HPC" (or "high-performance/specialist"); the second reads as an HPC engineer, the first as a legacy maintainer (§40.4). |
| 22 | False | A first contribution should be small, correct, and tested — maintainers value low-risk changes; big core changes from newcomers are hard to review and land (CS-01, §40.5). |
| 23 | b | A labeled measurement on stated hardware, validated — the only honest form; (a)/(c) are unsupportable universals, (d) is over-cautious (§40.4). |
| 24 | 100.00 | The lone interior point is $(u_{\text{top}} - 2u_c + u_{\text{below}}) + (\dots) = (100 - 0 + 0) + 0 = 100$; every boundary entry stays $0$ because the stencil fills only the interior (example-03; Ch 24). |
Justifications for short-answer and true/false items are the italic rationales above; award yourself the mark if your reasoning matches, even if the wording differs.
Topics to review by question
| If you missed… | Re-read |
|---|---|
| Q1, Q9, Q13 | §40.1 — who employs Fortran programmers |
| Q2, Q3, Q14, Q15 | §40.2 — the roles and the spectrum |
| Q4, Q7, Q8, Q10, Q17 | §40.3 — the shortage and scarcity-as-leverage |
| Q5, Q12, Q16 (framing), Q21, Q23 | §40.4 — presenting Fortran on a résumé |
| Q6, Q11, Q16 (artifacts), Q22 | §40.5 and the Project Checkpoint — contributing and packaging |
| Q18, Q19, Q24 | code/example-01, code/example-02, code/example-03 |
| Q20 | Broad review — Chapters 3 and 15 |
Note that the target rises with the four applied questions: aim for 19 / 24 on this expanded set.