Carefree (For Windows) 0.7
CareFree Library - A Light Data Generator for OI & ACM
载入中...
搜索中...
未找到
carefree.hpp 文件参考
#include <windows.h>
#include <psapi.h>
#include <io.h>
#include <sys/stat.h>
#include <unistd.h>
#include <algorithm>
#include <chrono>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <fstream>
#include <initializer_list>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <sstream>
#include <stdexcept>
#include <string>
#include <type_traits>
#include <typeinfo>
#include <vector>
carefree.hpp 的引用(Include)关系图:

浏览源代码.

struct  carefree_internal::carefree_exception_name
 
class  carefree_internal::carefree_exception< cpp_err_type, err_name >
 
struct  carefree_internal::carefree_invalid_argument_name
 
struct  carefree_internal::carefree_range_exception_name
 
struct  carefree_internal::carefree_unsupported_operation_name
 
struct  carefree_internal::carefree_file_exception_name
 
struct  carefree_internal::carefree_runtime_exception_name
 
struct  carefree_internal::carefree_system_exception_name
 
struct  carefree_internal::carefree_validate_failed_name
 
class  carefree_internal::_base_exception
 
class  carefree_internal::_unsupported_operation
 
class  carefree_internal::_file_exception
 
class  carefree_internal::_system_exception
 
class  carefree_internal::_validate_failed
 
class  carefree_internal::BalancedTree< T, Compare >
 
class  carefree_internal::graph
 
struct  carefree_internal::graph::edge
 
struct  carefree_internal::graph::weighted_output
 
struct  carefree_internal::graph::unweighted_output
 
class  carefree_internal::testcase_writer
 
class  carefree_internal::luogu_testcase_config_writer
 
class  carefree_internal::process_base
 
class  carefree_internal::process_win
 
struct  carefree_internal::judge_result
 
class  carefree_internal::comparator
 
class  carefree_internal::comparator::readable
 
class  carefree_internal::comparator::file
 
class  carefree_internal::comparator::text
 
class  carefree_internal::strict_comparator_naive
 
class  carefree_internal::strict_comparator
 
class  carefree_internal::token_comparator
 
class  carefree_internal::testlib_comparator
 
struct  carefree_internal::limprog
 
class  carefree_internal::gcc_compile
 
struct  carefree_internal::__enum_shortcut
 
class  carefree_internal::condition< T >
 

命名空间

namespace  carefree_internal
 
namespace  carefree_internal::strsets
 
namespace  carefree_internal::cpp_warnings
 
namespace  carefree_internal::pred
 
namespace  carefree_internal::pred::num
 
namespace  carefree_internal::pred::str
 
namespace  carefree_internal::pred::seq
 
namespace  carefree
 

宏定义

#define CAREFREE_VERSION_MAJOR   0
 
#define CAREFREE_VERSION_MINOR   7
 
#define CAREFREE_VERSION   "0.7"
 
#define maybe_unused   __attribute__((unused))
 

类型定义

using carefree_internal::_invalid_argument = std::invalid_argument
 
using carefree_internal::_range_exception = std::out_of_range
 
using carefree_internal::_runtime_exception = std::runtime_error
 
using carefree_internal::carefree_invalid_argument = carefree_exception<_invalid_argument, carefree_invalid_argument_name>
 
using carefree_internal::carefree_range_exception = carefree_exception<_range_exception, carefree_range_exception_name>
 
using carefree_internal::carefree_unsupported_operation = carefree_exception<_unsupported_operation, carefree_unsupported_operation_name>
 
using carefree_internal::carefree_file_exception = carefree_exception<_file_exception, carefree_file_exception_name>
 
using carefree_internal::carefree_runtime_exception = carefree_exception<_runtime_exception, carefree_runtime_exception_name>
 
using carefree_internal::carefree_system_exception = carefree_exception<_system_exception, carefree_system_exception_name>
 
using carefree_internal::carefree_validate_failed = carefree_exception<_validate_failed, carefree_validate_failed_name>
 
using carefree_internal::_Weight = long long
 
using carefree_internal::edge = graph::edge
 
using carefree_internal::weighted_output = graph::weighted_output
 
using carefree_internal::unweighted_output = graph::unweighted_output
 
using carefree_internal::process = process_win
 
using carefree_internal::ull = unsigned long long
 
using carefree_internal::creadable = comparator::readable
 
using carefree_internal::ctext = comparator::text
 
using carefree_internal::cfile = comparator::file
 
using carefree_internal::cpp_warnings::type = int
 

枚举

enum  carefree_internal::exception_policy { carefree_internal::Throw , carefree_internal::Ignore , carefree_internal::Friendly , carefree_internal::Simulate }
 
enum  carefree_internal::judge_result_type {
  carefree_internal::Accepted , carefree_internal::WrongAnswer , carefree_internal::TimeLimitExceeded , carefree_internal::MemoryLimitExceeded ,
  carefree_internal::RuntimeError , carefree_internal::CompileError , carefree_internal::PresentationError , carefree_internal::OutputLimitExceeded ,
  carefree_internal::UnknownError , carefree_internal::JudgeFailed , carefree_internal::PartiallyCorrect , carefree_internal::Skipped
}
 
enum  carefree_internal::optimization_type {
  carefree_internal::O0 , carefree_internal::O1 , carefree_internal::O2 , carefree_internal::O3 ,
  carefree_internal::Ofast
}
 
enum  carefree_internal::cpp_version {
  carefree_internal::Cpp98 , carefree_internal::Cpp03 , carefree_internal::Cpp11 , carefree_internal::Cpp14 ,
  carefree_internal::Cpp17 , carefree_internal::Cpp20
}
 

函数

constexpr unsigned long long operator""B (unsigned long long x)
 
constexpr unsigned long long operator""KiB (unsigned long long x)
 
constexpr unsigned long long operator""MiB (unsigned long long x)
 
constexpr unsigned long long operator""GiB (unsigned long long x)
 
constexpr unsigned long long operator""TiB (unsigned long long x)
 
constexpr unsigned long long operator""NS (unsigned long long x)
 
constexpr unsigned long long operator""MS (unsigned long long x)
 
constexpr unsigned long long operator""S (unsigned long long x)
 
constexpr unsigned long long operator""MIN (unsigned long long x)
 
exception_policy carefree_internal::get_exception_policy () noexcept
 
template<class T1 , class T2 >
void carefree_internal::raise (carefree_exception< T1, T2 > err)
 
template<class T >
void carefree_internal::err_range_checker (T l, T r, string func_name)
 
template<class T >
void carefree_internal::err_unempty_checker (T x, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_positive_checker (T x, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_natural_checker (T x, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_inrange_checker (T x, T l, T r, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_less_checker (T x, T l, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_greater_checker (T x, T l, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_leq_checker (T x, T l, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_geq_checker (T x, T l, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_equal_checker (T x, T l, string func_name, string var_name)
 
template<class T >
void carefree_internal::err_unequal_checker (T x, T l, string func_name, string var_name)
 
void carefree_internal::set_exception_policy (exception_policy policy)
 
template<class T1 , class T2 >
string carefree_internal::join_str (T1 a, T2 b)
 
template<class T >
string carefree_internal::__fts (T val, unsigned precision=10)
 
string carefree_internal::fts (float val, unsigned precision=10)
 
string carefree_internal::fts (double val, unsigned precision=10)
 
string carefree_internal::fts (long double val, unsigned precision=10)
 
template<class T >
std::vector< string > carefree_internal::fts (std::vector< T > val, unsigned precision=10)
 
template<class T >
std::vector< T > carefree_internal::ltv (std::initializer_list< T > val)
 
template<class T >
carefree_internal::randint (T l, T r)
 
template<class T >
carefree_internal::uniform (T l, T r)
 
double carefree_internal::random ()
 
template<class T >
T::value_type carefree_internal::choice (T val)
 
template<class T >
void carefree_internal::shuffle (T val)
 
template<class T , class Value >
std::vector< Value > carefree_internal::sequence (int n, T function)
 
template<class T >
std::vector< T > carefree_internal::sequence (int n, T l, T r)
 
template<class T >
std::vector< T > carefree_internal::sequence (int lengthL, int lengthR, T l, T r)
 
string carefree_internal::randstr (int length, const string sset=strsets::lower)
 
string carefree_internal::randstr (int lengthL, int lengthR, const string sset=strsets::lower)
 
template<class T >
double carefree_internal::timer (T function)
 
template<class T >
void carefree_internal::gen_data (int subtask_count, int task_per_subtask, T function)
 
template<class T >
void carefree_internal::gen_data (int task_count, T function)
 
 carefree_internal::__attribute__ ((constructor)) static void init_rnd_seed()
 
bool carefree_internal::is_tree (graph g)
 
graph carefree_internal::relabel (graph g)
 
graph carefree_internal::prufer_decode (int n, std::vector< int > prufer, _Weight weightL=0, _Weight weightR=0)
 
std::vector< int > carefree_internal::get_depth (graph g)
 
graph carefree_internal::introvert (graph tree)
 
graph carefree_internal::externalize (graph tree)
 
graph carefree_internal::lowhigh (int n, double low, double high, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::naive_tree (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::tail (int n, int k, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::chain (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::star (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::flower (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::max_degree (int n, int k, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::binary_tree (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::chain_star (int n, int k, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::silkworm (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::firecrackers (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::complete (int n, int k, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::complete_binary (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::random_tree (int n, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::dag (int n, int m, bool repeat_edges=false, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::connected_undirected_graph (int n, int m, bool repeat_edges=false, bool self_loop=false, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::connected_directed_graph (int n, int m, bool repeat_edges=false, bool self_loop=false, _Weight weightL=0, _Weight weightR=0)
 
graph carefree_internal::random_graph (int n, int m, bool directed=true, bool repeat_edges=false, bool self_loop=false, _Weight weightL=0, _Weight weightR=0)
 
string carefree_internal::jrt2s (judge_result_type type)
 
string carefree_internal::jrt2sf (judge_result_type type)
 
std::vector< string > carefree_internal::__split (const string &str, string delims)
 
ull carefree_internal::nextid ()
 
string carefree_internal::quote (string s)
 
judge_result carefree_internal::limited_run (limprog prog, const string &input_file, const string &output_file)
 
bool carefree_internal::is_file_creatable (string filename)
 
template<class T >
judge_result carefree_internal::judge (limprog prog, const string &input_file, const string &answer_file, T cmp, bool ole_check=true)
 
template<class T1 , class T2 >
bool carefree_internal::combat (limprog champion, limprog challenger, T1 input_generator, T2 cmp, int times=-1, bool ole_check=true)
 
void carefree_internal::listdir (string path, std::vector< string > &files)
 
string carefree_internal::working_directory ()
 
int carefree_internal::autoclear_tmpfiles ()
 
void carefree_internal::helloworld ()
 
template<class T >
condition< T > carefree_internal::operator|| (condition< T > a, condition< T > b)
 
template<class T >
condition< T > carefree_internal::operator&& (condition< T > a, condition< T > b)
 
template<class T >
condition< T > carefree_internal::operator! (condition< T > a)
 
template<class T >
condition< T > carefree_internal::operator| (condition< T > a, condition< T > b)
 
template<class T >
condition< T > carefree_internal::operator& (condition< T > a, condition< T > b)
 
template<class T >
condition< T > carefree_internal::pred::num::lt (T x)
 
template<class T >
condition< T > carefree_internal::pred::num::gt (T x)
 
template<class T >
condition< T > carefree_internal::pred::num::eq (T x)
 
template<class T >
condition< T > carefree_internal::pred::num::leq (T x)
 
template<class T >
condition< T > carefree_internal::pred::num::geq (T x)
 
template<class T >
condition< T > carefree_internal::pred::num::neq (T x)
 
template<class T >
condition< T > carefree_internal::pred::num::inrange (T l, T r)
 
condition< string > carefree_internal::pred::str::len_lt (size_t x)
 
condition< string > carefree_internal::pred::str::len_gt (size_t x)
 
condition< string > carefree_internal::pred::str::len_eq (size_t x)
 
condition< string > carefree_internal::pred::str::len_leq (size_t x)
 
condition< string > carefree_internal::pred::str::len_geq (size_t x)
 
condition< string > carefree_internal::pred::str::len_neq (size_t x)
 
condition< string > carefree_internal::pred::str::len_inrange (size_t l, size_t r)
 
condition< string > carefree_internal::pred::str::empty ()
 
condition< string > carefree_internal::pred::str::unempty ()
 
condition< string > carefree_internal::pred::str::sset (string s)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::len_lt (size_t x)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::len_gt (size_t x)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::len_eq (size_t x)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::len_leq (size_t x)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::len_geq (size_t x)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::len_neq (size_t x)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::len_inrange (size_t l, size_t r)
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::empty ()
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::unempty ()
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::increase ()
 
template<class T = int>
condition< std::vector< T > > carefree_internal::pred::seq::decrease ()
 

变量

exception_policy carefree_internal::exception_policy_val = exception_policy::Throw
 
std::mt19937_64 carefree_internal::public_random_engine
 
const string carefree_internal::strsets::lower = "abcdefghijklmnopqrstuvwxyz"
 
const string carefree_internal::strsets::upper = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
 
const string carefree_internal::strsets::digit = "0123456789"
 
const string carefree_internal::strsets::alphanum = lower + upper + digit
 
const string carefree_internal::strsets::alphabet = lower + upper
 
const string carefree_internal::strsets::slug = lower + digit + "-"
 
const string carefree_internal::strsets::var_name = lower + upper + digit + "_"
 
const string carefree_internal::strsets::bracket_general = "()[]{}<>"
 
const string carefree_internal::strsets::bracket = "()[]{}"
 
const string carefree_internal::strsets::quotes = "\"'"
 
const string carefree_internal::strsets::math_symbols_naive = "+-*"
 
const string carefree_internal::strsets::math_symbols_simple = "+-*/%"
 
const string carefree_internal::strsets::math_symbols = math_symbols_simple + "^"
 
const string carefree_internal::strsets::bool_symbols = "|&!"
 
const string carefree_internal::strsets::bitwise_symbols = bool_symbols + "~^"
 
const int carefree_internal::cpp_warnings::Wnone = 0
 
const int carefree_internal::cpp_warnings::Wall = 1
 
const int carefree_internal::cpp_warnings::Wextra = 2
 
const int carefree_internal::cpp_warnings::Wpedantic = 4
 
const int carefree_internal::cpp_warnings::Werror = 8
 
struct carefree_internal::__enum_shortcut carefree_internal::ES
 

宏定义说明

◆ CAREFREE_VERSION

#define CAREFREE_VERSION   "0.7"

◆ CAREFREE_VERSION_MAJOR

#define CAREFREE_VERSION_MAJOR   0

◆ CAREFREE_VERSION_MINOR

#define CAREFREE_VERSION_MINOR   7

◆ maybe_unused

#define maybe_unused   __attribute__((unused))

函数说明

◆ operator""B()

constexpr unsigned long long operator""B ( unsigned long long x)
constexpr

◆ operator""GiB()

constexpr unsigned long long operator""GiB ( unsigned long long x)
constexpr

◆ operator""KiB()

constexpr unsigned long long operator""KiB ( unsigned long long x)
constexpr

◆ operator""MiB()

constexpr unsigned long long operator""MiB ( unsigned long long x)
constexpr

◆ operator""MIN()

constexpr unsigned long long operator""MIN ( unsigned long long x)
constexpr

◆ operator""MS()

constexpr unsigned long long operator""MS ( unsigned long long x)
constexpr

◆ operator""NS()

constexpr unsigned long long operator""NS ( unsigned long long x)
constexpr

◆ operator""S()

constexpr unsigned long long operator""S ( unsigned long long x)
constexpr

◆ operator""TiB()

constexpr unsigned long long operator""TiB ( unsigned long long x)
constexpr