A software team is developing the autopilot control algorithm for an autonomous delivery drone. Throughout the source code, several key physical thresholds, such as the maximum safe wind speed and minimum voltage limit, are written as raw numerical values (e.g., 18.5 and 11.2).
Explain why replacing these literal values with descriptive, named constants improves both the readability and the maintainability of the codebase.
51 exam-style questions on Edexcel GCSE Computer Science Develop code, covering Decomposition and abstraction to solve problems, Read, write, analyse and refine programs, Converting algorithms into programs, Techniques for readable, maintainable code, Identifying and correcting program errors, and Evaluating program fitness and efficiency. Each one has a worked solution and a mark scheme showing where the marks go.