Generic programming: Difference between revisions

Content deleted Content added
Rescuing 1 sources and tagging 0 as dead.) #IABot (v2.0.9.5
Tags: Mobile edit Mobile web edit
Line 217:
<syntaxhighlight lang="cpp">
template <typename T>
[[nodiscard]]
constexpr T max(T x, T y) noexcept {
return x < y ? y : x;
}
Line 231 ⟶ 232:
 
<syntaxhighlight lang="cpp">
[[nodiscard]]
constexpr int max(int x, int y) noexcept {
return x < y ? y : x;
}