Compile Time Constants

Do We Use const keyword only for compile time constants? Explain

Questions by khan_khadri

Showing Answers 1 - 1 of 1 Answers

Const in C# is a compile time constant as it is closest considered like a #define of a literal value.It is used to define constant values. In C#, we can declare a const of any type as long as the value assigned can be fully evaluated at compile time. A const can be any type and value combination which can be determined at compile time.

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.


Related Answered Questions


Related Open Questions