3 ms·
Uh? Why couldn't a computation be constant? constexpr auto size = 4; constexpr std::array<int, size> arr = {1, 2, 3, 4}; constexpr auto i = 2;
by g15jv2dp 2y ago
Uh? Why couldn't a computation be constant?
constexpr auto size = 4;
constexpr std::array<int, size> arr = {1, 2, 3, 4};
constexpr auto i = 2;
constexpr auto x = arr[i];
- 38 2y agoyou dont have a computation in your code.
- g15jv2dp 2y agoconstexpr auto x = 1+1;
- entelechy0 2y ago[dead]