Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
// Compiles fine
int avg = average(std::vector<int>{1, 2, 4, 5});
// Does not compile
constexpr int avg = average(std::vector<int>{1, 2, 4, 5});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment