feat: implement CPP02 C++20 card
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
#include <iostream>
|
||||
constexpr int square(int value) { return value * value; }
|
||||
int main() {
|
||||
constexpr int result = square(7);
|
||||
const int limit{12};
|
||||
static_assert(result == 49);
|
||||
std::cout << "square=" << result << " limit=" << limit << '\n';
|
||||
}
|
||||
Reference in New Issue
Block a user