Practice C++ programming with coding exercises covering variables, data types, operators, input and output, type casting, conditional statements, loops, functions, arrays, and other C++ fundamentals.
const and #defineWrite a C++ program to demonstrate the use of const and #define for defining constant values.
The program should:
PI using #define.DAYS_IN_WEEK using const and assign it the value 7.PI and DAYS_IN_WEEK.radius and assign it the value 5.0.PI and radius.const variable cannot be changed after initialization.Expected Output:
Value of PI using #define: 3.14159
Days in a week using const: 7
Area of circle with radius 5 is: 78.5397
Write a C++ program that:
a = 5 and b = 2.c of type float.float before performing the division.c.c.2.5