Hi everyone,
Can anyone explain the purpose of using constant ? I know that constant is literal values, and it can be resued in multiple objects. Is there any purpose of using constant ? Moreover, when we will create constant in application ?
Thanks!
Discussion posts and replies are publicly visible
Constants give you two valuable outcomes:
Beware "magic numbers" in your code, makes it hard to read and, if used in more than one place, hard to maintain.