ユーザ定義リテラル (utility/literals.cpp)
- category: utility
-
View this file on GitHub
- Last commit date: 2020-07-11 14:53:01+09:00
Required by
- rank/select 辞書 (DataStructure/bit_vector.cpp)
- 動的ビットベクトル (DataStructure/dynamic_bitvector.cpp)
- 矩形クエリ (DataStructure/rectangle_query.cpp)
- sparse table (DataStructure/sparse_table.cpp)
- ウェーブレット行列 (DataStructure/wavelet_matrix.cpp)
- 最大流 (Dinitz 法) (Graph/dinitz.cpp)
- 最深共通祖先 (segment tree) (Graph/lowest_common_ancestor_segment_tree.cpp)
- 最深共通祖先 (sparse table) (Graph/lowest_common_ancestor_sparse_table.cpp)
- 最深共通祖先 (squaring) (Graph/lowest_common_ancestor_squaring.cpp)
- 線形計画法ソルバ (simplex 法) (Math/lp_solver.cpp)
- 連立合同式の解の構成 (ModularArithmetic/chinese_remaindering.cpp)
- mod 2^61-1 のローリングハッシュ (String/rolling_hash_l61m1.cpp)
- 接尾辞配列 + induced sort (String/sa_is.cpp)
- 接尾辞配列 (String/suffix_array.cpp)
- ロリハを衝突させるやつ (tree attack) (String/tree_attack.cpp)
- 高速 Möbius 変換 (algorithm/moebius_transform.cpp)
- 乗算との複合演算 (integer/fused_operations.cpp)
- 整数の乗算の上位ワード (integer/mul_upper.cpp)
- オーバーフロー判定つき演算 (integer/overflow.cpp)
- 4-近傍 (utility/four_neighbor.cpp)
Verified with
- test/aoj_0613.test.cpp
- test/aoj_2178.test.cpp
- test/aoj_2313.test.cpp
- test/aoj_2446.test.cpp
- test/aoj_2580.test.cpp
- test/aoj_2911.test.cpp
- test/aoj_2970.test.cpp
- test/aoj_2976.test.cpp
- test/aoj_3110.test.cpp
- test/aoj_3111.test.cpp
- test/aoj_3112.test.cpp
- test/aoj_3112_sa_is.test.cpp
- test/aoj_ALDS1_14_B_l61m1.test.cpp
- test/aoj_ALDS1_5_D.test.cpp
- test/aoj_DPL_1_D.test.cpp
- test/aoj_GRL_5_C_segment_tree.test.cpp
- test/aoj_GRL_5_C_sparse_table.test.cpp
- test/aoj_GRL_5_C_squaring.test.cpp
- test/mini/fused_operations.test.cpp
- test/yc_1036_sparse_table.test.cpp
- test/yc_3014.test.cpp
- test/yc_878.test.cpp
- test/yc_878_reversed.test.cpp
- test/yj_bipartitematching.test.cpp
- test/yj_lca_squaring.test.cpp
- test/yj_range_kth_smallest.test.cpp
- test/yj_rectangle_sum.test.cpp
- test/yj_suffixarray.test.cpp
Code
#ifndef H_int_literals
#define H_int_literals
/**
* @brief ユーザ定義リテラル
* @author えびちゃん
*/
#include <cstddef>
#include <cstdint>
constexpr intmax_t operator ""_jd(unsigned long long n) { return n; }
constexpr uintmax_t operator ""_ju(unsigned long long n) { return n; }
constexpr size_t operator ""_zu(unsigned long long n) { return n; }
constexpr ptrdiff_t operator ""_td(unsigned long long n) { return n; }
constexpr int8_t operator ""_i8(unsigned long long n) { return n; }
constexpr int16_t operator ""_i16(unsigned long long n) { return n; }
constexpr int32_t operator ""_i32(unsigned long long n) { return n; }
constexpr int64_t operator ""_i64(unsigned long long n) { return n; }
constexpr uint8_t operator ""_u8(unsigned long long n) { return n; }
constexpr uint16_t operator ""_u16(unsigned long long n) { return n; }
constexpr uint32_t operator ""_u32(unsigned long long n) { return n; }
constexpr uint64_t operator ""_u64(unsigned long long n) { return n; }
#endif /* !defined(H_int_literals) */
#line 1 "utility/literals.cpp"
/**
* @brief ユーザ定義リテラル
* @author えびちゃん
*/
#include <cstddef>
#include <cstdint>
constexpr intmax_t operator ""_jd(unsigned long long n) { return n; }
constexpr uintmax_t operator ""_ju(unsigned long long n) { return n; }
constexpr size_t operator ""_zu(unsigned long long n) { return n; }
constexpr ptrdiff_t operator ""_td(unsigned long long n) { return n; }
constexpr int8_t operator ""_i8(unsigned long long n) { return n; }
constexpr int16_t operator ""_i16(unsigned long long n) { return n; }
constexpr int32_t operator ""_i32(unsigned long long n) { return n; }
constexpr int64_t operator ""_i64(unsigned long long n) { return n; }
constexpr uint8_t operator ""_u8(unsigned long long n) { return n; }
constexpr uint16_t operator ""_u16(unsigned long long n) { return n; }
constexpr uint32_t operator ""_u32(unsigned long long n) { return n; }
constexpr uint64_t operator ""_u64(unsigned long long n) { return n; }