-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwhatever.hpp
36 lines (31 loc) · 1.17 KB
/
whatever.hpp
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: wcorrea- <wcorrea-@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/09/04 19:26:35 by wcorrea- #+# #+# */
/* Updated: 2023/09/09 00:21:27 by wcorrea- ### ########.fr */
/* */
/* ************************************************************************** */
#pragma once
#include <iostream>
#include <string>
template <typename T>
void swap(T &a, T &b)
{
T tmp = a;
a = b;
b = tmp;
}
template <typename T>
T const &min(T const &a, T const &b)
{
return (a < b ? a : b);
}
template <typename T>
T const &max(T const &a, T const &b)
{
return (a > b ? a : b);
}