cplit/
lib.rs

1//! # Competitive Programming Library
2//!
3//! This library aims to provide a set of algorithm, data structure and tools for competitive programming.
4//!
5//! There are several philosophies behind this library:
6//! - **Simple**: The library should be simple and fast to use, as time is precious in competitive programming.
7//!     - Do not overuse Option, Result to provide unnecessary boundary checks (panic is fine).
8//! - **Extensible**: Most of algorithms and data structures should not be limited to a specific type.
9//!     - Design genetic traits to allow different types to be used (including potentially user-defined types like matrices).
10//! - **Efficient**: The library should be efficient enough for competitive programming problems.
11//! - **Comprehensive**: The library should be readable and understandable for educational purposes.
12//! - **Tested**: The library should be tested with some problems from online judges to ensure its correctness.
13//! - **Indexed from _1_**: The library should use 1-based index for most of the algorithms and data structures while leaving the index 0 for buffer manipulation.
14//!     - This is because most of the problem use 1-based index.
15//!     - Index 0 should default be set to ZERO.
16//!
17//!
18//! ## Examples
19//!
20//! ```no_run
21//! use cplit::scanln;
22//!
23//! fn main() {
24//!     let (a, b): (usize, usize);
25//!     scanln!(a, b);
26//!     println!("{}", a + b);
27//! }
28//! ```
29#![allow(clippy::needless_doctest_main)]
30
31pub mod data_structure;
32pub mod general;
33pub mod geometry;
34pub mod graph;
35pub mod num;
36pub mod number_theory;
37pub mod utils;
38
39#[macro_use]
40mod macros;