-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwhatever.hpp
More file actions
36 lines (31 loc) · 1.19 KB
/
whatever.hpp
File metadata and controls
36 lines (31 loc) · 1.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* whatever.hpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: zelhajou <zelhajou@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/01/01 21:20:02 by zelhajou #+# #+# */
/* Updated: 2025/01/01 21:20:13 by zelhajou ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef WHATEVER_HPP
#define WHATEVER_HPP
template <typename T>
void swap(T &a, T &b)
{
T temp = a;
a = b;
b = temp;
}
template <typename T>
const T &min(const T &a, const T &b)
{
return (a < b) ? a : b;
}
template <typename T>
const T &max(const T &a, const T &b)
{
return (a > b) ? a : b;
}
#endif