| 6 | double power(double x, int n); // Redundant declaration (harmless) |
| 7 | |
| 8 | int main() |
| 9 | { |
| 10 | for (int i{ -3 }; i <= 3; ++i) // Calculate powers of 8 from -3 to +3 |
| 11 | std::cout << std::format("{:10}\n", power(8.0, i)); |
| 12 | std::cout << std::endl; |
| 13 | } |
| 14 | |
| 15 | double power(double x, int n) // A first definition |
| 16 | { |