blob: 4d8d5a5f8ca2d6eb741e986733a53a3bca54da28 (
plain)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
#pragma once
template <typename T>
static inline constexpr auto signum(T x)
{
return x < T(0) ? -1 : 1;
}
#include <cmath>
using std::copysign;
using std::sqrt;
using std::pow;
using std::fabs;
using std::fmin;
using std::fmax;
using std::atan;
using std::atan2;
using std::asin;
using std::acos;
using std::sin;
using std::cos;
using std::tan;
using std::round;
using std::fmod;
using std::log;
using std::log2;
using std::log10;
using std::exp;
#include <cinttypes>
using std::uintptr_t;
using std::intptr_t;
using std::int64_t;
using std::int32_t;
using std::int8_t;
using std::uint64_t;
using std::uint32_t;
using std::uint8_t;
#include <algorithm>
using std::min;
using std::max;
|