#include <iostream>
using namespace std;
constexpr int sum(int a, int b) {
return a + b;
}
int main() {
static_assert(sum(3,8) == 11, "compile-time evaluation");
//uncomment line below to get an error even though sum only evaluates to true
//static_assert((bool)sum(3,rand()%8), "irrelevant message");
std::cout << sum(3,rand()%8) << std::endl;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKY29uc3RleHByIGludCBzdW0oaW50IGEsIGludCBiKSB7CglyZXR1cm4gYSArIGI7Cn0KCmludCBtYWluKCkgewoJc3RhdGljX2Fzc2VydChzdW0oMyw4KSA9PSAxMSwgImNvbXBpbGUtdGltZSBldmFsdWF0aW9uIik7CgkvL3VuY29tbWVudCBsaW5lIGJlbG93IHRvIGdldCBhbiBlcnJvciBldmVuIHRob3VnaCBzdW0gb25seSBldmFsdWF0ZXMgdG8gdHJ1ZQoJLy9zdGF0aWNfYXNzZXJ0KChib29sKXN1bSgzLHJhbmQoKSU4KSwgImlycmVsZXZhbnQgbWVzc2FnZSIpOwoJCglzdGQ6OmNvdXQgPDwgc3VtKDMscmFuZCgpJTgpIDw8IHN0ZDo6ZW5kbDsKfQ==