- Exercise

In this exercise, you will explore constant expressions on your own.

We'll cover the following

Try It Out!

Task 1

Use the structure MyDouble in your program. How can you check that instances of MyDouble will be created at compile time?

Task 2

What will happen if MyDouble is used in a non-constant expression?

Get hands-on with 1400+ tech skills courses.