- Use
constfor variables that shouldn’t change andconstexprfor values that can be computed at compile time. This improves readability and can optimize performance.
const for variables that shouldn’t change and constexpr for values that can be computed at compile time. This improves readability and can optimize performance.
Leave a Reply