From 26446e32d089d8f42ecf541a6b0b797f08c42a8d Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Mon, 15 Dec 2025 14:22:51 -0600 Subject: [PATCH 01/10] fix(codeforces): cleanup 954 a --- codeforces/954/a.cc | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/codeforces/954/a.cc b/codeforces/954/a.cc index 2c8526a..340661e 100644 --- a/codeforces/954/a.cc +++ b/codeforces/954/a.cc @@ -43,14 +43,7 @@ void solve() { for (auto& e : a) cin >> e; sort(begin(a), end(a)); - u32 ans = 1e9; - for (i32 c = 1; c <= 10; ++c) { - u32 diff = 0; - for (auto e : a) diff += abs(c - e); - ans = min(ans, diff); - } - - println("{}", ans); + println("{}", a[1] - a[0] + a[2] - a[1]); } int main() { // {{{ From dfa21f9de35d725ef11f1396cef36770f9de1a9d Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Tue, 16 Dec 2025 00:53:22 -0600 Subject: [PATCH 02/10] feat(codeforces): more div3 as --- codeforces/780/.clang-format | 17 +++++++ codeforces/780/a.cc | 69 ++++++++++++++++++++++++++++ codeforces/786/.clang-format | 17 +++++++ codeforces/786/a.cc | 66 ++++++++++++++++++++++++++ codeforces/787/.clang-format | 17 +++++++ codeforces/787/a.cc | 78 +++++++++++++++++++++++++++++++ codeforces/797/.clang-format | 17 +++++++ codeforces/797/a.cc | 80 ++++++++++++++++++++++++++++++++ codeforces/805/.clang-format | 17 +++++++ codeforces/805/a.cc | 73 +++++++++++++++++++++++++++++ codeforces/811/.clang-format | 17 +++++++ codeforces/811/a.cc | 89 ++++++++++++++++++++++++++++++++++++ codeforces/820/.clang-format | 17 +++++++ codeforces/820/a.cc | 69 ++++++++++++++++++++++++++++ codeforces/834/.clang-format | 17 +++++++ codeforces/834/a.cc | 74 ++++++++++++++++++++++++++++++ codeforces/839/.clang-format | 17 +++++++ codeforces/839/a.cc | 64 ++++++++++++++++++++++++++ codeforces/847/.clang-format | 17 +++++++ codeforces/847/a.cc | 71 ++++++++++++++++++++++++++++ codeforces/855/.clang-format | 17 +++++++ codeforces/855/a.cc | 81 ++++++++++++++++++++++++++++++++ codeforces/863/.clang-format | 17 +++++++ codeforces/863/a.cc | 73 +++++++++++++++++++++++++++++ codeforces/867/.clang-format | 17 +++++++ codeforces/867/a.cc | 74 ++++++++++++++++++++++++++++++ codeforces/878/.clang-format | 17 +++++++ codeforces/878/a.cc | 75 ++++++++++++++++++++++++++++++ codeforces/881/.clang-format | 17 +++++++ codeforces/881/a.cc | 74 ++++++++++++++++++++++++++++++ codeforces/905/.clang-format | 17 +++++++ codeforces/905/a.cc | 78 +++++++++++++++++++++++++++++++ codeforces/909/.clang-format | 17 +++++++ codeforces/909/a.cc | 67 +++++++++++++++++++++++++++ codeforces/913/.clang-format | 17 +++++++ codeforces/913/a.cc | 79 ++++++++++++++++++++++++++++++++ codeforces/916/.clang-format | 17 +++++++ codeforces/916/a.cc | 79 ++++++++++++++++++++++++++++++++ codeforces/925/.clang-format | 17 +++++++ codeforces/925/a.cc | 76 ++++++++++++++++++++++++++++++ codeforces/927/.clang-format | 17 +++++++ codeforces/927/a.cc | 78 +++++++++++++++++++++++++++++++ codeforces/933/.clang-format | 17 +++++++ codeforces/933/a.cc | 77 +++++++++++++++++++++++++++++++ 44 files changed, 2018 insertions(+) create mode 100644 codeforces/780/.clang-format create mode 100644 codeforces/780/a.cc create mode 100644 codeforces/786/.clang-format create mode 100644 codeforces/786/a.cc create mode 100644 codeforces/787/.clang-format create mode 100644 codeforces/787/a.cc create mode 100644 codeforces/797/.clang-format create mode 100644 codeforces/797/a.cc create mode 100644 codeforces/805/.clang-format create mode 100644 codeforces/805/a.cc create mode 100644 codeforces/811/.clang-format create mode 100644 codeforces/811/a.cc create mode 100644 codeforces/820/.clang-format create mode 100644 codeforces/820/a.cc create mode 100644 codeforces/834/.clang-format create mode 100644 codeforces/834/a.cc create mode 100644 codeforces/839/.clang-format create mode 100644 codeforces/839/a.cc create mode 100644 codeforces/847/.clang-format create mode 100644 codeforces/847/a.cc create mode 100644 codeforces/855/.clang-format create mode 100644 codeforces/855/a.cc create mode 100644 codeforces/863/.clang-format create mode 100644 codeforces/863/a.cc create mode 100644 codeforces/867/.clang-format create mode 100644 codeforces/867/a.cc create mode 100644 codeforces/878/.clang-format create mode 100644 codeforces/878/a.cc create mode 100644 codeforces/881/.clang-format create mode 100644 codeforces/881/a.cc create mode 100644 codeforces/905/.clang-format create mode 100644 codeforces/905/a.cc create mode 100644 codeforces/909/.clang-format create mode 100644 codeforces/909/a.cc create mode 100644 codeforces/913/.clang-format create mode 100644 codeforces/913/a.cc create mode 100644 codeforces/916/.clang-format create mode 100644 codeforces/916/a.cc create mode 100644 codeforces/925/.clang-format create mode 100644 codeforces/925/a.cc create mode 100644 codeforces/927/.clang-format create mode 100644 codeforces/927/a.cc create mode 100644 codeforces/933/.clang-format create mode 100644 codeforces/933/a.cc diff --git a/codeforces/780/.clang-format b/codeforces/780/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/780/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/780/a.cc b/codeforces/780/a.cc new file mode 100644 index 0000000..a88876e --- /dev/null +++ b/codeforces/780/a.cc @@ -0,0 +1,69 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 a, b; + cin >> a >> b; + if (b == 0) { + println("{}", a + 1); + } else if (a == 0) { + println("{}", 1); + } else { + println("{}", 2 * b + a + 1); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/786/.clang-format b/codeforces/786/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/786/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/786/a.cc b/codeforces/786/a.cc new file mode 100644 index 0000000..caa37ca --- /dev/null +++ b/codeforces/786/a.cc @@ -0,0 +1,66 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 x, y; + cin >> x >> y; + + if (y % x > 0) { + println("0 0"); + } else { + println("1 {}", y / x); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/787/.clang-format b/codeforces/787/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/787/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/787/a.cc b/codeforces/787/a.cc new file mode 100644 index 0000000..f94437f --- /dev/null +++ b/codeforces/787/a.cc @@ -0,0 +1,78 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 a, b, c, y, x; + cin >> a >> b >> c >> x >> y; + + x -= min(x, a); + y -= min(y, b); + + if (x > 0) { + u32 diff = min(x, c); + x -= diff; + c -= diff; + } + + if (y > 0) { + u32 diff = min(y, c); + y -= diff; + } + + println("{}", (x == y && x == 0) ? "YES" : "NO"); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/797/.clang-format b/codeforces/797/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/797/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/797/a.cc b/codeforces/797/a.cc new file mode 100644 index 0000000..960e964 --- /dev/null +++ b/codeforces/797/a.cc @@ -0,0 +1,80 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + + u32 a = n / 3, b = n / 3, c = n / 3; + + switch (n % 3) { + case 0: + ++b; + --c; + break; + case 1: + b += 2; + --c; + break; + case 2: + ++a; + b += 2; + --c; + break; + } + + println("{} {} {}", a, b, c); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/805/.clang-format b/codeforces/805/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/805/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/805/a.cc b/codeforces/805/a.cc new file mode 100644 index 0000000..6eb8282 --- /dev/null +++ b/codeforces/805/a.cc @@ -0,0 +1,73 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + u32 N = n; + u32 dcount = 0; + while (N > 0) { + ++dcount; + N /= 10; + } + + u32 base = 1; + for (u32 i = 0; i + 1 < dcount; ++i) { + base *= 10; + } + + println("{}", n - base); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/811/.clang-format b/codeforces/811/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/811/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/811/a.cc b/codeforces/811/a.cc new file mode 100644 index 0000000..b9e0a60 --- /dev/null +++ b/codeforces/811/a.cc @@ -0,0 +1,89 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + i32 n, H, M; + cin >> n >> H >> M; + + pair A{H,M}; + + vector> alarms(n); + for (auto& e : alarms) { + cin >> e.first >> e.second; + } + + sort(begin(alarms), end(alarms)); + + i32 ans = 0; + + for (i32 i = 0; i < n; ++i) { + auto& alarm = alarms[i]; + if (alarm >= A) { + ans = i; + break; + } + } + + auto& alarm = alarms[ans]; + i32 diff = abs(alarm.first * 60 + alarm.second - (A.first * 60 + A.second)); + if (alarm < A) { + diff = 24 * 60 - diff; + } + + println("{} {}", diff / 60, diff % 60); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/820/.clang-format b/codeforces/820/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/820/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/820/a.cc b/codeforces/820/a.cc new file mode 100644 index 0000000..60d462d --- /dev/null +++ b/codeforces/820/a.cc @@ -0,0 +1,69 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + i32 a, b, c; + cin >> a >> b >> c; + + i32 A = a - 1; + i32 B = abs(c - b) + c - 1; + + if (A == B) { + println("3"); + } else { + println("{}", A < B ? 1 : 2); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/834/.clang-format b/codeforces/834/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/834/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/834/a.cc b/codeforces/834/a.cc new file mode 100644 index 0000000..c70dd81 --- /dev/null +++ b/codeforces/834/a.cc @@ -0,0 +1,74 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +string Yes = "Yes"; + +void solve() { + string s; + cin >> s; + + for (u32 i = 0; i < s.size(); ++i) { + auto c = s[i]; + if (Yes.find(c) == string::npos || + i + 1 < s.size() && !(c == 'Y' && s[i + 1] == 'e' || c == 'e' && s[i + 1] == 's' || + c == 's' && s[i + 1] == 'Y')) { + println("NO"); + return; + } + } + + println("YES"); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/839/.clang-format b/codeforces/839/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/839/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/839/a.cc b/codeforces/839/a.cc new file mode 100644 index 0000000..23f52a1 --- /dev/null +++ b/codeforces/839/a.cc @@ -0,0 +1,64 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + string s; + cin >> s; + + println("{}", s[0] - '0' + s[2] - '0'); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/847/.clang-format b/codeforces/847/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/847/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/847/a.cc b/codeforces/847/a.cc new file mode 100644 index 0000000..833e241 --- /dev/null +++ b/codeforces/847/a.cc @@ -0,0 +1,71 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +string PI = "3141592653589793238462643383279"; + +void solve() { + string s; + cin >> s; + + u32 i = 0; + while (i < PI.size() && s[i] == PI[i]) { + ++i; + } + + println("{}", i); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/855/.clang-format b/codeforces/855/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/855/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/855/a.cc b/codeforces/855/a.cc new file mode 100644 index 0000000..f39bb2b --- /dev/null +++ b/codeforces/855/a.cc @@ -0,0 +1,81 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + string s; + cin >> n >> s; + + // NOTE: cannot due `for (auto c : "meow")` <- c-style string, includes null-terminator + string S{"meow"}; + + u32 i = 0; + for (auto c : S) { + u32 j = i; + while (j < n && tolower(s[j]) == c) { + ++j; + } + if (i == j) { + i = 0; + break; + } + i = j; + } + + println("{}", i == n ? "YES" : "NO"); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/863/.clang-format b/codeforces/863/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/863/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/863/a.cc b/codeforces/863/a.cc new file mode 100644 index 0000000..2966e2d --- /dev/null +++ b/codeforces/863/a.cc @@ -0,0 +1,73 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + char d; + string s; + cin >> n >> d >> s; + + for (u32 i = 0; i < n; ++i) { + if (d > s[i] || d == s[i] && i + 1 < n && d > s[i + 1]) { + println("{}{}{}", s.substr(0, i), d, s.substr(i)); + return; + } + } + + println("{}{}", s, d); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/867/.clang-format b/codeforces/867/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/867/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/867/a.cc b/codeforces/867/a.cc new file mode 100644 index 0000000..91553bd --- /dev/null +++ b/codeforces/867/a.cc @@ -0,0 +1,74 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n, t; + cin >> n >> t; + array ans{-1, -1}; + vector a(n), b(n); + for (u32 i = 0; i < n; ++i) { + cin >> a[i]; + } + for (u32 i = 0; i < n; ++i) { + cin >> b[i]; + } + for (u32 i = 1; i <= n; ++i) { + if (i - 1 + a[i - 1] <= t) { + ans = max(ans, {b[i - 1], i}); + } + } + println("{}", ans[1] == -1 ? -1 : ans[1]); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/878/.clang-format b/codeforces/878/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/878/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/878/a.cc b/codeforces/878/a.cc new file mode 100644 index 0000000..96696d4 --- /dev/null +++ b/codeforces/878/a.cc @@ -0,0 +1,75 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + string s; + cin >> n >> s; + + u32 i = 0; + string ans; + for (u32 j = 1; j < n; ++j) { + if (s[j] == s[i]) { + ans.push_back(s[i]); + i = j + 1; + ++j; + } + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/881/.clang-format b/codeforces/881/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/881/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/881/a.cc b/codeforces/881/a.cc new file mode 100644 index 0000000..0bd367b --- /dev/null +++ b/codeforces/881/a.cc @@ -0,0 +1,74 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + vector a(n); + for (auto& e : a) cin >> e; + + sort(begin(a), end(a)); + + u32 ans = 0; + + for (u32 i = 0; i < n / 2; ++i) { + ans += a[n - i - 1] - a[i]; + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/905/.clang-format b/codeforces/905/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/905/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/905/a.cc b/codeforces/905/a.cc new file mode 100644 index 0000000..23f7ae5 --- /dev/null +++ b/codeforces/905/a.cc @@ -0,0 +1,78 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +string keys = "1234567890"; +vector m(10); + +void solve() { + string s; + cin >> s; + + u32 ans = 4; + + char last = '1'; + for (auto c : s) { + ans += abs(m[c - '0'] - m[last - '0']); + last = c; + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (i32 i = 0; i < keys.size(); ++i) { + m[keys[i] - '0'] = i; + } + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/909/.clang-format b/codeforces/909/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/909/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/909/a.cc b/codeforces/909/a.cc new file mode 100644 index 0000000..1a56db3 --- /dev/null +++ b/codeforces/909/a.cc @@ -0,0 +1,67 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + if (n % 3 == 1 || n % 3 == 2) { + println("First"); + } else { + println("Second"); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/913/.clang-format b/codeforces/913/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/913/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/913/a.cc b/codeforces/913/a.cc new file mode 100644 index 0000000..3ac3a12 --- /dev/null +++ b/codeforces/913/a.cc @@ -0,0 +1,79 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + char C; + u32 x; + cin >> C >> x; + + for (u32 r = 1; r <= 8; ++r) { + if (r == x) { + continue; + } + + println("{}{}", C, r); + } + + for (char c = 'a'; c <= 'h'; ++c) { + if (c == C) { + continue; + } + + println("{}{}", c, x); + } + + println(); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/916/.clang-format b/codeforces/916/.clang-format new file mode 100644 index 0000000..99733d1 --- /dev/null +++ b/codeforces/916/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 4 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/916/a.cc b/codeforces/916/a.cc new file mode 100644 index 0000000..78df74f --- /dev/null +++ b/codeforces/916/a.cc @@ -0,0 +1,79 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +vector f('Z' - 'A' + 1); + +void solve() { + u32 n; + cin >> n; + string s; + cin >> s; + f.assign(f.size(), 0); + + for (auto& e : s) { + ++f[e - 'A']; + } + + u32 ans = 0; + + for (u32 i = 1; i <= f.size(); ++i) { + ans += f[i - 1] >= i; + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/925/.clang-format b/codeforces/925/.clang-format new file mode 100644 index 0000000..99733d1 --- /dev/null +++ b/codeforces/925/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 4 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/925/a.cc b/codeforces/925/a.cc new file mode 100644 index 0000000..c716e65 --- /dev/null +++ b/codeforces/925/a.cc @@ -0,0 +1,76 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +map m; + +void solve() { + u32 n; + cin >> n; + + string ans = "aaa"; + + u32 index = 2; + for (u32 i = 1; i <= n - 3; ++i) { + if (ans[index] == 'z') { + --index; + } + ++ans[index]; + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/927/.clang-format b/codeforces/927/.clang-format new file mode 100644 index 0000000..99733d1 --- /dev/null +++ b/codeforces/927/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 4 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/927/a.cc b/codeforces/927/a.cc new file mode 100644 index 0000000..5bfa67a --- /dev/null +++ b/codeforces/927/a.cc @@ -0,0 +1,78 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + string s; + cin >> s; + + u32 ans = 0; + char last = '.'; + for (auto c : s) { + if (last == '*' && c == '*') { + break; + } + if (c == '@') { + ++ans; + } + last = c; + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/933/.clang-format b/codeforces/933/.clang-format new file mode 100644 index 0000000..99733d1 --- /dev/null +++ b/codeforces/933/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 4 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/933/a.cc b/codeforces/933/a.cc new file mode 100644 index 0000000..b160b8f --- /dev/null +++ b/codeforces/933/a.cc @@ -0,0 +1,77 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n, m, k; + cin >> n >> m >> k; + vector a(n), b(m); + for (auto& e : a) cin >> e; + for (auto& e : b) cin >> e; + + u32 ans = 0; + + for (u32 i = 1; i <= n; ++i) { + for (u32 j = 1; j <= m; ++j) { + if (a[i - 1] + b[j - 1] <= k) { + ++ans; + } + } + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} From 70cc4b84367beb11942f3f1ccdf097df2b2da869 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Fri, 19 Dec 2025 02:22:40 -0600 Subject: [PATCH 03/10] feat(codeforces): 10 more div 3s --- codeforces/.clang-format | 17 ++++++++ codeforces/725/.clang-format | 17 ++++++++ codeforces/725/a.cc | 68 ++++++++++++++++++++++++++++++++ codeforces/731/.clang-format | 17 ++++++++ codeforces/731/a.cc | 69 ++++++++++++++++++++++++++++++++ codeforces/734/.clang-format | 17 ++++++++ codeforces/734/a.cc | 65 ++++++++++++++++++++++++++++++ codeforces/739/.clang-format | 17 ++++++++ codeforces/739/a.cc | 70 +++++++++++++++++++++++++++++++++ codeforces/744/.clang-format | 17 ++++++++ codeforces/744/a.cc | 70 +++++++++++++++++++++++++++++++++ codeforces/748/.clang-format | 17 ++++++++ codeforces/748/a.cc | 65 ++++++++++++++++++++++++++++++ codeforces/753/.clang-format | 17 ++++++++ codeforces/753/a.cc | 73 ++++++++++++++++++++++++++++++++++ codeforces/756/.clang-format | 17 ++++++++ codeforces/756/a.cc | 76 ++++++++++++++++++++++++++++++++++++ codeforces/760/.clang-format | 17 ++++++++ codeforces/760/a.cc | 65 ++++++++++++++++++++++++++++++ codeforces/764/.clang-format | 17 ++++++++ codeforces/764/a.cc | 65 ++++++++++++++++++++++++++++++ codeforces/776/.clang-format | 17 ++++++++ codeforces/776/a.cc | 72 ++++++++++++++++++++++++++++++++++ codeforces/811/a.cc | 30 ++++---------- 24 files changed, 970 insertions(+), 22 deletions(-) create mode 100644 codeforces/.clang-format create mode 100644 codeforces/725/.clang-format create mode 100644 codeforces/725/a.cc create mode 100644 codeforces/731/.clang-format create mode 100644 codeforces/731/a.cc create mode 100644 codeforces/734/.clang-format create mode 100644 codeforces/734/a.cc create mode 100644 codeforces/739/.clang-format create mode 100644 codeforces/739/a.cc create mode 100644 codeforces/744/.clang-format create mode 100644 codeforces/744/a.cc create mode 100644 codeforces/748/.clang-format create mode 100644 codeforces/748/a.cc create mode 100644 codeforces/753/.clang-format create mode 100644 codeforces/753/a.cc create mode 100644 codeforces/756/.clang-format create mode 100644 codeforces/756/a.cc create mode 100644 codeforces/760/.clang-format create mode 100644 codeforces/760/a.cc create mode 100644 codeforces/764/.clang-format create mode 100644 codeforces/764/a.cc create mode 100644 codeforces/776/.clang-format create mode 100644 codeforces/776/a.cc diff --git a/codeforces/.clang-format b/codeforces/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/725/.clang-format b/codeforces/725/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/725/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/725/a.cc b/codeforces/725/a.cc new file mode 100644 index 0000000..4af7488 --- /dev/null +++ b/codeforces/725/a.cc @@ -0,0 +1,68 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + i32 n; + cin >> n; + vector a(n); + for (auto &e : a) + cin >> e; + + i32 i = distance(begin(a), max_element(begin(a), end(a))); + i32 j = distance(begin(a), min_element(begin(a), end(a))); + + println("{}", min({max(i, j) + 1, n - min(i, j), min(i, j) + 1 + n - max(i, j)})); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/731/.clang-format b/codeforces/731/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/731/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/731/a.cc b/codeforces/731/a.cc new file mode 100644 index 0000000..7eee3c5 --- /dev/null +++ b/codeforces/731/a.cc @@ -0,0 +1,69 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + i32 x1, y1, x2, y2, x3, y3; + cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3; + + i32 ans = abs(y2 - y1) + abs(x2 - x1); + if (x1 == x2 && x2 == x3 && min(y1, y2) <= y3 && y3 <= max(y1, y2)) { + ans += 2; + } else if (y1 == y2 && y2 == y3 && min(x1, x2) <= x3 && x3 <= max(x1, x2)) { + ans += 2; + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/734/.clang-format b/codeforces/734/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/734/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/734/a.cc b/codeforces/734/a.cc new file mode 100644 index 0000000..904c9f1 --- /dev/null +++ b/codeforces/734/a.cc @@ -0,0 +1,65 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + + array ans{0, n / 3, n / 3}; + ++ans[n % 3]; + + println("{} {}", ans[1], ans[2]); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/739/.clang-format b/codeforces/739/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/739/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/739/a.cc b/codeforces/739/a.cc new file mode 100644 index 0000000..43272b9 --- /dev/null +++ b/codeforces/739/a.cc @@ -0,0 +1,70 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 k; + cin >> k; + + u32 ans = 1, i = 1; + while (i < k) { + ++ans; + if (!(ans % 3 == 0 || ans % 10 == 3)) { + ++i; + } + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/744/.clang-format b/codeforces/744/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/744/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/744/a.cc b/codeforces/744/a.cc new file mode 100644 index 0000000..458dda6 --- /dev/null +++ b/codeforces/744/a.cc @@ -0,0 +1,70 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + string s; + cin >> s; + + u32 b = 0; + for (auto c : s) + b += c == 'B'; + + if (s.size() % 2 == 0 && b == s.size() / 2) { + println("YES"); + } else { + println("NO"); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/748/.clang-format b/codeforces/748/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/748/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/748/a.cc b/codeforces/748/a.cc new file mode 100644 index 0000000..03923a1 --- /dev/null +++ b/codeforces/748/a.cc @@ -0,0 +1,65 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + i32 a, b, c; + cin >> a >> b >> c; + + println("{} {} {}", + max({0, b - a + 1, c - a + 1}), + max({0, a - b + 1, c - b + 1}), + max({0, b - c + 1, a - c + 1})); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/753/.clang-format b/codeforces/753/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/753/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/753/a.cc b/codeforces/753/a.cc new file mode 100644 index 0000000..fe30e22 --- /dev/null +++ b/codeforces/753/a.cc @@ -0,0 +1,73 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + string a, s; + cin >> a >> s; + map m; + for (u32 i = 0; i < a.size(); ++i) { + m[a[i]] = i; + } + + i32 ans = 0; + for (i32 i = 1; i < s.size(); ++i) { + ans += abs(m[s[i]] - m[s[i - 1]]); + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/756/.clang-format b/codeforces/756/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/756/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/756/a.cc b/codeforces/756/a.cc new file mode 100644 index 0000000..b4c1e93 --- /dev/null +++ b/codeforces/756/a.cc @@ -0,0 +1,76 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + string s; + cin >> s; + + if ((s.back() - '0') % 2 == 0) { + println("0"); + } else if ((s[0] - '0') % 2 == 0) { + println("1"); + } else { + for (auto c : s) { + if ((c - '0') % 2 == 0) { + println("2"); + return; + } + } + println("-1"); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/760/.clang-format b/codeforces/760/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/760/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/760/a.cc b/codeforces/760/a.cc new file mode 100644 index 0000000..df261aa --- /dev/null +++ b/codeforces/760/a.cc @@ -0,0 +1,65 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + vector ss(7); + for (auto& e : ss) cin >> e; + sort(begin(ss), end(ss)); + + println("{} {} {}", ss[0], ss[1], ss.back() - (ss[0] + ss[1])); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/764/.clang-format b/codeforces/764/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/764/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/764/a.cc b/codeforces/764/a.cc new file mode 100644 index 0000000..443625f --- /dev/null +++ b/codeforces/764/a.cc @@ -0,0 +1,65 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + vector a(n); + for (auto &e : a) + cin >> e; + + println("{}", *max_element(begin(a), end(a)) - *min_element(begin(a), end(a))); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/776/.clang-format b/codeforces/776/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/776/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/776/a.cc b/codeforces/776/a.cc new file mode 100644 index 0000000..7bd90b5 --- /dev/null +++ b/codeforces/776/a.cc @@ -0,0 +1,72 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + char c; + string s; + cin >> s >> c; + + for (u32 i = 0; i < s.size(); ++i) { + if (s[i] == c && i % 2 == 0 && (s.size() - i - 1) % 2 == 0) { + println("YES"); + return; + } + } + + println("NO"); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/811/a.cc b/codeforces/811/a.cc index b9e0a60..44fd9d6 100644 --- a/codeforces/811/a.cc +++ b/codeforces/811/a.cc @@ -39,35 +39,21 @@ constexpr T MAX = std::numeric_limits::max(); // }}} void solve() { - i32 n, H, M; + i32 n, H, M, h, m; cin >> n >> H >> M; - pair A{H,M}; - - vector> alarms(n); - for (auto& e : alarms) { - cin >> e.first >> e.second; - } - - sort(begin(alarms), end(alarms)); - - i32 ans = 0; + i32 ans = 24 * 60; for (i32 i = 0; i < n; ++i) { - auto& alarm = alarms[i]; - if (alarm >= A) { - ans = i; - break; + cin >> h >> m; + i32 diff = h * 60 + m - (H * 60 + M); + if (diff < 0) { + diff += 24 * 60; } + ans = min(ans, diff); } - auto& alarm = alarms[ans]; - i32 diff = abs(alarm.first * 60 + alarm.second - (A.first * 60 + A.second)); - if (alarm < A) { - diff = 24 * 60 - diff; - } - - println("{} {}", diff / 60, diff % 60); + println("{} {}", ans / 60, ans % 60); } int main() { // {{{ From 4c531b965f289bae70672858e47d39b4ccc26984 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Sun, 21 Dec 2025 01:45:36 -0600 Subject: [PATCH 04/10] more codeforces --- codeforces/702/.clang-format | 17 ++++++++ codeforces/702/a.cc | 78 ++++++++++++++++++++++++++++++++++ codeforces/710/.clang-format | 17 ++++++++ codeforces/710/a.cc | 67 +++++++++++++++++++++++++++++ codeforces/713/.clang-format | 17 ++++++++ codeforces/713/a.cc | 73 ++++++++++++++++++++++++++++++++ codeforces/719/.clang-format | 17 ++++++++ codeforces/719/a.cc | 81 ++++++++++++++++++++++++++++++++++++ 8 files changed, 367 insertions(+) create mode 100644 codeforces/702/.clang-format create mode 100644 codeforces/702/a.cc create mode 100644 codeforces/710/.clang-format create mode 100644 codeforces/710/a.cc create mode 100644 codeforces/713/.clang-format create mode 100644 codeforces/713/a.cc create mode 100644 codeforces/719/.clang-format create mode 100644 codeforces/719/a.cc diff --git a/codeforces/702/.clang-format b/codeforces/702/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/702/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/702/a.cc b/codeforces/702/a.cc new file mode 100644 index 0000000..fb87a87 --- /dev/null +++ b/codeforces/702/a.cc @@ -0,0 +1,78 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + vector a(n); + for(auto& e : a) cin >> e; + + u32 ans = 0; + + for (u32 i = 1; i < n; ++i) { + u32 A = max(a[i - 1], a[i]); + u32 B = min(a[i - 1], a[i]); + + while (B * 2 < A) { + ++ans; + B *= 2; + } + } + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/710/.clang-format b/codeforces/710/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/710/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/710/a.cc b/codeforces/710/a.cc new file mode 100644 index 0000000..9f91d01 --- /dev/null +++ b/codeforces/710/a.cc @@ -0,0 +1,67 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + i64 n, m, x; + cin >> n >> m >> x; + + i64 row = x % n; + if (row == 0) + row = n; + i64 col = (x + n - 1) / n; + + println("{}", (row - 1) * m + col); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/713/.clang-format b/codeforces/713/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/713/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/713/a.cc b/codeforces/713/a.cc new file mode 100644 index 0000000..6674b36 --- /dev/null +++ b/codeforces/713/a.cc @@ -0,0 +1,73 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + vector a(n); + map f; + for (auto &e : a) { + cin >> e; + ++f[e]; + } + + for (u32 i = 0; i < n; ++i) { + if (f[a[i]] == 1) { + println("{}", i + 1); + return; + } + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} diff --git a/codeforces/719/.clang-format b/codeforces/719/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/719/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/719/a.cc b/codeforces/719/a.cc new file mode 100644 index 0000000..24663c4 --- /dev/null +++ b/codeforces/719/a.cc @@ -0,0 +1,81 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i16 = int16_t; +using u16 = uint16_t; +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +bitset<26> seen; + +void solve() { + seen.reset(); + u32 n; + string s; + cin >> n >> s; + + for (u32 i = 0; i < n; ++i) { + if (seen[s[i]]) { + println("NO"); + return; + } + + seen[s[i]] = true; + + while (i + 1 < n && s[i] == s[i + 1]) { + ++i; + } + } + + println("YES"); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} +// }}} From 69d48861b1dd310079d141e661069c06c7b263d9 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Wed, 7 Jan 2026 12:30:51 -0600 Subject: [PATCH 05/10] icpc probs --- codeforces/1037/a.cc | 3 +- codeforces/1071/.clang-format | 17 +++++ codeforces/1071/a.cc | 62 ++++++++++++++++++ kattis/10-9-2024/1/input.txt | 0 kattis/10-9-2024/1/script.py | 15 +++++ kattis/10-9-2024/3/input.txt | 2 + kattis/10-9-2024/3/script.py | 44 +++++++++++++ kattis/10-9-2024/4/script.py | 54 ++++++++++++++++ kattis/10-9-2024/contest.md | 3 + kattis/23-9-24/b/input.txt | 23 +++++++ kattis/23-9-24/b/solution.py | 117 ++++++++++++++++++++++++++++++++++ kattis/23-9-24/contest.md | 3 + kattis/23-9-24/d/input.txt | 1 + kattis/23-9-24/d/solution.py | 46 +++++++++++++ kattis/23-9-24/e/solution.py | 22 +++++++ kattis/23-9-24/f/input.txt | 6 ++ kattis/23-9-24/f/solution.py | 32 ++++++++++ 17 files changed, 448 insertions(+), 2 deletions(-) create mode 100644 codeforces/1071/.clang-format create mode 100644 codeforces/1071/a.cc create mode 100644 kattis/10-9-2024/1/input.txt create mode 100644 kattis/10-9-2024/1/script.py create mode 100644 kattis/10-9-2024/3/input.txt create mode 100644 kattis/10-9-2024/3/script.py create mode 100644 kattis/10-9-2024/4/script.py create mode 100644 kattis/10-9-2024/contest.md create mode 100644 kattis/23-9-24/b/input.txt create mode 100644 kattis/23-9-24/b/solution.py create mode 100644 kattis/23-9-24/contest.md create mode 100644 kattis/23-9-24/d/input.txt create mode 100644 kattis/23-9-24/d/solution.py create mode 100644 kattis/23-9-24/e/solution.py create mode 100644 kattis/23-9-24/f/input.txt create mode 100644 kattis/23-9-24/f/solution.py diff --git a/codeforces/1037/a.cc b/codeforces/1037/a.cc index 47ffe9d..bac1114 100644 --- a/codeforces/1037/a.cc +++ b/codeforces/1037/a.cc @@ -82,5 +82,4 @@ int main() { // {{{ } return 0; -} -// }}} +} // vim: set foldmethod=marker foldmarker={{{{{{,}}}}}} diff --git a/codeforces/1071/.clang-format b/codeforces/1071/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/1071/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/1071/a.cc b/codeforces/1071/a.cc new file mode 100644 index 0000000..93807a7 --- /dev/null +++ b/codeforces/1071/a.cc @@ -0,0 +1,62 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} + +// }}} + +// vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/kattis/10-9-2024/1/input.txt b/kattis/10-9-2024/1/input.txt new file mode 100644 index 0000000..e69de29 diff --git a/kattis/10-9-2024/1/script.py b/kattis/10-9-2024/1/script.py new file mode 100644 index 0000000..8d37a7d --- /dev/null +++ b/kattis/10-9-2024/1/script.py @@ -0,0 +1,15 @@ +n, a = list(map(int, input().split())) + +es = list(map(int, input().split())) + +es.sort() + +won = 0 + +for e in es: + if a <= e: + break + won += 1 + a -= (e + 1) + +print(won) diff --git a/kattis/10-9-2024/3/input.txt b/kattis/10-9-2024/3/input.txt new file mode 100644 index 0000000..c68b729 --- /dev/null +++ b/kattis/10-9-2024/3/input.txt @@ -0,0 +1,2 @@ +10 15 +10 11 12 13 14 15 diff --git a/kattis/10-9-2024/3/script.py b/kattis/10-9-2024/3/script.py new file mode 100644 index 0000000..af25fa5 --- /dev/null +++ b/kattis/10-9-2024/3/script.py @@ -0,0 +1,44 @@ +from math import gcd + +a, b = map(int, input().split()) +max_num = float('-inf') + +transcript = input().split() + +fizzs = [] +buzzs = [] + +for i, token in enumerate(transcript): + num = a + i + + max_num = max(max_num, num) + + if token.startswith("Fizz") or token.endswith("Fizz"): + fizzs.append(num) + if token.startswith("Buzz") or token.endswith("Buzz"): + buzzs.append(num) + + +def gcf(nums: list[int]) -> int: + if not nums: + return '' + if len(nums) == 1: + return nums[0] + + x, y = nums[0], nums[1] + ans = gcd(x, y) + + for i in range(2, len(nums)): + ans = gcd(ans, nums[i]) + + return ans + + +a, b = gcf(fizzs), gcf(buzzs) + +if a == '': + a = max_num + 1 +if b == '': + b = max_num + 1 + +print(a, b) diff --git a/kattis/10-9-2024/4/script.py b/kattis/10-9-2024/4/script.py new file mode 100644 index 0000000..5fee760 --- /dev/null +++ b/kattis/10-9-2024/4/script.py @@ -0,0 +1,54 @@ +N = int(input()) + +matrix: list[list[int]] = [] +for i in range(N): + matrix[i] = list(map(int, list(input()))) + +row_map = [0] * N +col_map = [0] * N + +ones_above = 0 +ones_above_row = [0] * N + +for i, row in enumerate(matrix): + ones_above_row[i] = ones_above + total = 0 + for cell in row: + total += cell + row_map[i] = total + ones_above += row_map[i] + +ones_left = 0 +ones_left_col = [0] * N + +for col in range(N): + total = 0 + for row in range(N): + total += matrix[row][col] + ones_left_col[col] = ones_left + col_map[col] = total + ones_left += col_map[col] + +found_valid_row = False +for i in range(N): + flips_remain = row_map[i] + total_ones = ones_above_row[-1] - row_map[i] + row_map[-1] + if total_ones <= flips_remain: + row_flag = True + break + +found_valid_col = False +for i in range(N): + flips_remain = col_map[i] + total_ones = ones_left_col[-1] - col_map[i] + col_map[-1] + if total_ones <= flips_remain: + found_valid_col = True + break + +if found_valid_row: + if found_valid_col: + print("+") + else: + print("-") +else: + print("-") diff --git a/kattis/10-9-2024/contest.md b/kattis/10-9-2024/contest.md new file mode 100644 index 0000000..9a0693a --- /dev/null +++ b/kattis/10-9-2024/contest.md @@ -0,0 +1,3 @@ +# contest 1 + +https://open.kattis.com/contests/asurii diff --git a/kattis/23-9-24/b/input.txt b/kattis/23-9-24/b/input.txt new file mode 100644 index 0000000..4165880 --- /dev/null +++ b/kattis/23-9-24/b/input.txt @@ -0,0 +1,23 @@ +2 + +.#.#.#.#.# +#.#.#.#.#. +.#.#.B.#.# +#.#.#.#.#. +.#.#.B.#.# +#.#.W.#.#. +.#.#.#.#.# +#.#.#.B.#. +.#.#.#.#.# +#.#.#.#.#. + +.#.#.#.#.# +#.#.#.#.#. +.#.#.B.#.# +#.B.#.B.#. +.#.#.B.#.# +#.B.W.#.#. +.#.B.B.#.# +#.#.#.#.#. +.#.B.B.#.# +#.#.#.#.#. diff --git a/kattis/23-9-24/b/solution.py b/kattis/23-9-24/b/solution.py new file mode 100644 index 0000000..e95ce65 --- /dev/null +++ b/kattis/23-9-24/b/solution.py @@ -0,0 +1,117 @@ +""" +Backtracking Framework +- Set of choices +- Limited by constraints +- To reach a goal + +1. Understand +- Board of W/B, can capture; looking for max consecutive sequence of captures using same piece +- Capture in any direction "skipping over"; land on open square + +Similar Problems: N Queens + +Set of candidates (W pieces) limited in moves (capturing B pieces) to reach max # captures (i.e. capturing moves) +2. Develop + +- Given board state, w/ W candidates +- Consider every candidate as the piece yielding correct answer +- For every candidate, consider every capturing move they can make + - For each move: + - Make the move, and recursively find max # captures using this piece after this capture + - update/restore state on failure + - Update max if new max found + +consider after: caching/optimization + +backtracking function: def max_captures(board, w) -> int: + + +3. Carry Out +4. Revise + +At any particular position, +""" + +BOARD_SIZE = 10 + + +def parse_board() -> tuple[list[list[str]], list[tuple[int, int]]]: + board = [] + candidates: list[tuple[int, int]] = [] + + input() + + for r in range(BOARD_SIZE): + board.append(list(input())) + + candidates.extend((r, c) for c, cell in enumerate(board[-1]) if cell == "W") + + return board, candidates + + +def valid(board, r, c): + return 0 <= r < len(board) and 0 <= c < len(board[0]) + + +# all capturing moves white piece can make +def capturing_moves(board, r, c) -> list[tuple[int, int]]: + if not valid(board, r, c): + return [] + + moves = [] + + for dr, dc in [(-1, -1), (1, 1), (-1, 1), (1, -1)]: + if ( + valid(board, r + 2 * dr, c + 2 * dc) + and board[r + dr][c + dc] == "B" + and board[r + 2 * dr][c + 2 * dc] not in "BW" + ): + moves.append((dr, dc)) + + return moves + + +def max_candidate_captures(board, r, c) -> int: + max_captures = 0 + + for dr, dc in capturing_moves(board, r, c): + # place + board[r][c] = "." + board[r + dr][c + dc] = "." + board[r + dr * 2][c + dc * 2] = "W" + + ans = max_candidate_captures(board, r + dr * 2, c + dc * 2) + max_captures = max(max_captures, 1 + ans) + + # unplace + board[r + dr * 2][c + dc * 2] = "." + board[r][c] = "W" + board[r + dr][c + dc] = "B" + + return max_captures + + +def max_captures(board, candidates: list[tuple[int, int]]) -> int: + max_captures = 0 + + for r, c in candidates: + max_captures = max(max_captures, max_candidate_captures(board, r, c)) + + return max_captures + + +def solve() -> None: + T = int(input()) + + while T: + board, candidates = parse_board() + print(max_captures(board, candidates)) + T -= 1 + + +def main() -> None: + solve() + + +if __name__ == "__main__": + main() diff --git a/kattis/23-9-24/contest.md b/kattis/23-9-24/contest.md new file mode 100644 index 0000000..065a704 --- /dev/null +++ b/kattis/23-9-24/contest.md @@ -0,0 +1,3 @@ +# contest 2 + +https://open.kattis.com/contests/wrrf23 diff --git a/kattis/23-9-24/d/input.txt b/kattis/23-9-24/d/input.txt new file mode 100644 index 0000000..b188259 --- /dev/null +++ b/kattis/23-9-24/d/input.txt @@ -0,0 +1 @@ +(2+(2*2)+2) diff --git a/kattis/23-9-24/d/solution.py b/kattis/23-9-24/d/solution.py new file mode 100644 index 0000000..68054c9 --- /dev/null +++ b/kattis/23-9-24/d/solution.py @@ -0,0 +1,46 @@ +def solve(equation: str) -> None: + stack = [] + paren_pairs = [] + + for i, token in enumerate(equation): + if token == "(": + stack.append([i, None]) + elif token == ")": + l, r = stack.pop() + r = i + paren_pairs.append((l, r)) + + P = [[]] + + for paren_pair in paren_pairs: + P.extend([[paren_pair] + p for p in P]) + + def format(permutation): + output = list(equation) + + for l, r in permutation: + output[l] = None + output[r] = None + + return "".join(filter(lambda token: token, output)) + + seen = set() + ans = [] + for permutation in P[1:]: + output = format(permutation) + if output not in seen: + seen.add(output) + ans.append(output) + + for x in sorted(ans): + print(x) + + +def main() -> None: + equation = input() + + solve(equation) + + +if __name__ == "__main__": + main() diff --git a/kattis/23-9-24/e/solution.py b/kattis/23-9-24/e/solution.py new file mode 100644 index 0000000..32811c7 --- /dev/null +++ b/kattis/23-9-24/e/solution.py @@ -0,0 +1,22 @@ +ALPHABET = "ABCDEFGHIJKLMNOPQRSTUVWXYZ_." + +character_to_index = {c: i for i, c in enumerate(ALPHABET)} +index_to_character = {i: c for i, c in enumerate(ALPHABET)} + +while line := input(): + split = line.split() + + if len(split) == 1: + break + + k, string = int(split[0]), split[1] + + backwards = string[::-1] + + ans: list[str] = [] + + for letter in backwards: + index = character_to_index[letter] + ans.append(index_to_character[(index + k) % len(ALPHABET)]) + + print("".join(ans)) diff --git a/kattis/23-9-24/f/input.txt b/kattis/23-9-24/f/input.txt new file mode 100644 index 0000000..35b50fd --- /dev/null +++ b/kattis/23-9-24/f/input.txt @@ -0,0 +1,6 @@ +Will Smith +Agent Smith +Peter Pan +Micky Mouse +Minnie Mouse +Peter Gunn diff --git a/kattis/23-9-24/f/solution.py b/kattis/23-9-24/f/solution.py new file mode 100644 index 0000000..dbfae37 --- /dev/null +++ b/kattis/23-9-24/f/solution.py @@ -0,0 +1,32 @@ +import sys +from collections import Counter + + +def solve() -> None: + counter: Counter[str] = Counter() + + ans = [] + + lines = sys.stdin.readlines() + for line in lines: + first, last = line.split() + + counter[first] += 1 + + ans.append((last, first)) + + ans.sort() + + for last, first in ans: + if counter[first] > 1: + print(f"{first} {last}") + else: + print(first) + + +def main() -> None: + solve() + + +if __name__ == "__main__": + main() From f3b09b52273510a4230691221f190f1a1da57cb1 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Thu, 15 Jan 2026 18:05:00 -0500 Subject: [PATCH 06/10] update readme --- readme.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/readme.md b/readme.md index 9f29833..cec2ad2 100644 --- a/readme.md +++ b/readme.md @@ -1,5 +1,7 @@ # competitive programming -an archive of competitive programming code +a collection of my competitive programming solutions categorized as follows: -codeforces account: [frozenpipe](https://codeforces.com/profile/frozenpipe) +- `/kattis`: a few ICPC problems from UVA's "practices" +- `/codeforces`: codeforces contests, including every division 4 round +- `/cses`: ~100 basic cses problems From 00dd91267e9e05c50ad19b965f04c1f05ed9dd2e Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Thu, 15 Jan 2026 18:05:06 -0500 Subject: [PATCH 07/10] move readme --- readme.md => README.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename readme.md => README.md (100%) diff --git a/readme.md b/README.md similarity index 100% rename from readme.md rename to README.md From 3445a7d0017a9f0cccc0328558335d90c38330bd Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Sun, 25 Jan 2026 22:12:54 -0500 Subject: [PATCH 08/10] feat(1074): some more prob;ems --- codeforces/1074/.clang-format | 17 +++++++ codeforces/1074/a.cc | 62 ++++++++++++++++++++++++++ codeforces/1074/b.cc | 66 ++++++++++++++++++++++++++++ codeforces/1074/c.cc | 78 ++++++++++++++++++++++++++++++++ codeforces/1074/d.cc | 83 +++++++++++++++++++++++++++++++++++ codeforces/1074/e.cc | 69 +++++++++++++++++++++++++++++ 6 files changed, 375 insertions(+) create mode 100644 codeforces/1074/.clang-format create mode 100644 codeforces/1074/a.cc create mode 100644 codeforces/1074/b.cc create mode 100644 codeforces/1074/c.cc create mode 100644 codeforces/1074/d.cc create mode 100644 codeforces/1074/e.cc diff --git a/codeforces/1074/.clang-format b/codeforces/1074/.clang-format new file mode 100644 index 0000000..59cd6f1 --- /dev/null +++ b/codeforces/1074/.clang-format @@ -0,0 +1,17 @@ +BasedOnStyle: LLVM +IndentWidth: 2 +UseTab: Never + +AllowShortIfStatementsOnASingleLine: Never +AllowShortLoopsOnASingleLine: false +AllowShortFunctionsOnASingleLine: None +AllowShortLambdasOnASingleLine: None +AllowShortBlocksOnASingleLine: Never +AllowShortEnumsOnASingleLine: false +AllowShortCaseExpressionOnASingleLine: false + +BreakBeforeBraces: Attach +ColumnLimit: 100 +AlignAfterOpenBracket: Align +BinPackArguments: false +BinPackParameters: false diff --git a/codeforces/1074/a.cc b/codeforces/1074/a.cc new file mode 100644 index 0000000..b2e4942 --- /dev/null +++ b/codeforces/1074/a.cc @@ -0,0 +1,62 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + for (u32 i = 1; i <= n; ++i) { + print("{}{}", i, " \n"[i==n]); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/codeforces/1074/b.cc b/codeforces/1074/b.cc new file mode 100644 index 0000000..b3942f1 --- /dev/null +++ b/codeforces/1074/b.cc @@ -0,0 +1,66 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + u64 x = 0, a; + for (u32 i = 1; i <= n; ++i) { + cin >> a; + x = max(x, a); + } + + println("{}", x * n); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/codeforces/1074/c.cc b/codeforces/1074/c.cc new file mode 100644 index 0000000..ba0251d --- /dev/null +++ b/codeforces/1074/c.cc @@ -0,0 +1,78 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n; + cin >> n; + vector a(n); + for (auto &e : a) + cin >> e; + + sort(begin(a), end(a)); + a.erase(unique(begin(a), end(a)), end(a)); + + u32 ans = 1, streak = 1; + + for (u32 i = 1; i < a.size(); ++i) { + if (i > 0 && a[i] - 1 == a[i - 1]) { + ++streak; + } else { + ans = max(ans, streak); + streak = 1; + } + } + + ans = max(ans, streak); + + println("{}", ans); +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/codeforces/1074/d.cc b/codeforces/1074/d.cc new file mode 100644 index 0000000..6a5d1a0 --- /dev/null +++ b/codeforces/1074/d.cc @@ -0,0 +1,83 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +bitset<2 * 100000 + 1> dirty; +void solve() { + dirty.reset(); + u32 n, m; + u64 h; + cin >> n >> m >> h; + vector> a(n); + for (u32 i = 0; i < n; ++i) { + cin >> a[i].first; + a[i].second = a[i].first; + } + + u64 b, c; + for (u32 i = 0; i < m; ++i) { + cin >> b >> c; + --b; + if (dirty[b]) { + dirty[b] = false; + a[b].second = a[b].first; + } + a[b].second += c; + if (a[b].second > h) { + dirty.set(); + } + } + + for (u32 i = 0; i < n; ++i) { + print("{}{}", dirty[i] ? a[i].first : a[i].second, " \n"[i == n - 1]); + } +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/codeforces/1074/e.cc b/codeforces/1074/e.cc new file mode 100644 index 0000000..7506375 --- /dev/null +++ b/codeforces/1074/e.cc @@ -0,0 +1,69 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template constexpr T MIN = std::numeric_limits::min(); + +template constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + u32 n, m, k; + + cin >> n >> m >> k; + + vector a(n), b(m); + + for (u32 i = 0; i < n; ++i) { + cin >> a[i]; + } + + for (u32 i = 0; i < m; ++i) { + cin >> b[i]; + } + +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} From 6cea7c9766c90415ab11308b5b2304549e949ac4 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Sun, 25 Jan 2026 22:14:05 -0500 Subject: [PATCH 09/10] fix: purge clang-formats --- .gitignore | 1 + atcoder/042/.clang-format | 9 --------- codeforces/1003/.clang-format | 9 --------- codeforces/1006/.clang-format | 9 --------- codeforces/1009/.clang-format | 9 --------- codeforces/1013/.clang-format | 9 --------- codeforces/1016/.clang-format | 9 --------- codeforces/1017/.clang-format | 9 --------- codeforces/1020/.clang-format | 9 --------- codeforces/1027/.clang-format | 17 ----------------- codeforces/1029/.clang-format | 9 --------- codeforces/1032/.clang-format | 9 --------- codeforces/1034/.clang-format | 9 --------- codeforces/1037/.clang-format | 9 --------- codeforces/1042/.clang-format | 5 ----- codeforces/1043/.clang-format | 9 --------- codeforces/1047/.clang-format | 5 ----- codeforces/1059/.clang-format | 5 ----- codeforces/1071/.clang-format | 17 ----------------- codeforces/1074/.clang-format | 17 ----------------- codeforces/17/.clang-format | 17 ----------------- codeforces/19/.clang-format | 4 ---- codeforces/431/.clang-format | 9 --------- codeforces/479/.clang-format | 4 ---- codeforces/498/.clang-format | 17 ----------------- codeforces/506/.clang-format | 4 ---- codeforces/515/.clang-format | 5 ----- codeforces/544/.clang-format | 4 ---- codeforces/547/.clang-format | 4 ---- codeforces/550/.clang-format | 4 ---- codeforces/552/.clang-format | 4 ---- codeforces/555/.clang-format | 4 ---- codeforces/560/.clang-format | 4 ---- codeforces/565/.clang-format | 17 ----------------- codeforces/570/.clang-format | 17 ----------------- codeforces/575/.clang-format | 17 ----------------- codeforces/611/.clang-format | 4 ---- codeforces/640/.clang-format | 2 -- codeforces/702/.clang-format | 17 ----------------- codeforces/710/.clang-format | 17 ----------------- codeforces/713/.clang-format | 17 ----------------- codeforces/719/.clang-format | 17 ----------------- codeforces/725/.clang-format | 17 ----------------- codeforces/731/.clang-format | 17 ----------------- codeforces/734/.clang-format | 17 ----------------- codeforces/739/.clang-format | 17 ----------------- codeforces/744/.clang-format | 17 ----------------- codeforces/748/.clang-format | 17 ----------------- codeforces/753/.clang-format | 17 ----------------- codeforces/756/.clang-format | 17 ----------------- codeforces/760/.clang-format | 17 ----------------- codeforces/762/.clang-format | 9 --------- codeforces/764/.clang-format | 17 ----------------- codeforces/776/.clang-format | 17 ----------------- codeforces/780/.clang-format | 17 ----------------- codeforces/784/.clang-format | 9 --------- codeforces/786/.clang-format | 17 ----------------- codeforces/787/.clang-format | 17 ----------------- codeforces/790/.clang-format | 9 --------- codeforces/797/.clang-format | 17 ----------------- codeforces/799/.clang-format | 9 --------- codeforces/805/.clang-format | 17 ----------------- codeforces/806/.clang-format | 9 --------- codeforces/811/.clang-format | 17 ----------------- codeforces/817/.clang-format | 9 --------- codeforces/820/.clang-format | 17 ----------------- codeforces/827/.clang-format | 9 --------- codeforces/834/.clang-format | 17 ----------------- codeforces/835/.clang-format | 9 --------- codeforces/839/.clang-format | 17 ----------------- codeforces/847/.clang-format | 17 ----------------- codeforces/849/.clang-format | 9 --------- codeforces/855/.clang-format | 17 ----------------- codeforces/859/.clang-format | 9 --------- codeforces/863/.clang-format | 17 ----------------- codeforces/867/.clang-format | 17 ----------------- codeforces/871/.clang-format | 9 --------- codeforces/874/.clang-format | 9 --------- codeforces/878/.clang-format | 17 ----------------- codeforces/881/.clang-format | 17 ----------------- codeforces/886/.clang-format | 9 --------- codeforces/888/.clang-format | 9 --------- codeforces/891/.clang-format | 9 --------- codeforces/894/.clang-format | 9 --------- codeforces/895/.clang-format | 9 --------- codeforces/898/.clang-format | 9 --------- codeforces/900/.clang-format | 9 --------- codeforces/903/.clang-format | 9 --------- codeforces/905/.clang-format | 17 ----------------- codeforces/909/.clang-format | 17 ----------------- codeforces/913/.clang-format | 17 ----------------- codeforces/916/.clang-format | 17 ----------------- codeforces/918/.clang-format | 9 --------- codeforces/920/.clang-format | 9 --------- codeforces/923/.clang-format | 9 --------- codeforces/925/.clang-format | 17 ----------------- codeforces/927/.clang-format | 17 ----------------- codeforces/928/.clang-format | 9 --------- codeforces/929/.clang-format | 9 --------- codeforces/933/.clang-format | 17 ----------------- codeforces/935/.clang-format | 9 --------- codeforces/937/.clang-format | 9 --------- codeforces/938/.clang-format | 9 --------- codeforces/943/.clang-format | 17 ----------------- codeforces/944/.clang-format | 9 --------- codeforces/946/.clang-format | 4 ---- codeforces/950/.clang-format | 17 ----------------- codeforces/952/.clang-format | 9 --------- codeforces/954/.clang-format | 17 ----------------- codeforces/957/.clang-format | 9 --------- codeforces/962/.clang-format | 9 --------- codeforces/964/.clang-format | 9 --------- codeforces/966/.clang-format | 17 ----------------- codeforces/970/.clang-format | 9 --------- codeforces/971/.clang-format | 9 --------- codeforces/974/.clang-format | 2 -- codeforces/981/.clang-format | 9 --------- codeforces/988/.clang-format | 17 ----------------- codeforces/993/.clang-format | 9 --------- codeforces/995/.clang-format | 9 --------- codeforces/996/.clang-format | 9 --------- codeforces/998/.clang-format | 9 --------- cses/dynamic-programming/.clang-format | 9 --------- cses/graph-algorithms/.clang-format | 9 --------- cses/introductory-problems/.clang-format | 9 --------- cses/range-queries/.clang-format | 9 --------- cses/sorting-and-searching/.clang-format | 9 --------- kattis/11-02-2025/.clang-format | 9 --------- kattis/18-2-2025/.clang-format | 9 --------- kattis/25-2-2025/.clang-format | 9 --------- usaco/bronze/simulation/.clang-format | 9 --------- 131 files changed, 1 insertion(+), 1485 deletions(-) delete mode 100644 atcoder/042/.clang-format delete mode 100644 codeforces/1003/.clang-format delete mode 100644 codeforces/1006/.clang-format delete mode 100644 codeforces/1009/.clang-format delete mode 100644 codeforces/1013/.clang-format delete mode 100644 codeforces/1016/.clang-format delete mode 100644 codeforces/1017/.clang-format delete mode 100644 codeforces/1020/.clang-format delete mode 100644 codeforces/1027/.clang-format delete mode 100644 codeforces/1029/.clang-format delete mode 100644 codeforces/1032/.clang-format delete mode 100644 codeforces/1034/.clang-format delete mode 100644 codeforces/1037/.clang-format delete mode 100644 codeforces/1042/.clang-format delete mode 100644 codeforces/1043/.clang-format delete mode 100644 codeforces/1047/.clang-format delete mode 100644 codeforces/1059/.clang-format delete mode 100644 codeforces/1071/.clang-format delete mode 100644 codeforces/1074/.clang-format delete mode 100644 codeforces/17/.clang-format delete mode 100644 codeforces/19/.clang-format delete mode 100644 codeforces/431/.clang-format delete mode 100644 codeforces/479/.clang-format delete mode 100644 codeforces/498/.clang-format delete mode 100644 codeforces/506/.clang-format delete mode 100644 codeforces/515/.clang-format delete mode 100644 codeforces/544/.clang-format delete mode 100644 codeforces/547/.clang-format delete mode 100644 codeforces/550/.clang-format delete mode 100644 codeforces/552/.clang-format delete mode 100644 codeforces/555/.clang-format delete mode 100644 codeforces/560/.clang-format delete mode 100644 codeforces/565/.clang-format delete mode 100644 codeforces/570/.clang-format delete mode 100644 codeforces/575/.clang-format delete mode 100644 codeforces/611/.clang-format delete mode 100644 codeforces/640/.clang-format delete mode 100644 codeforces/702/.clang-format delete mode 100644 codeforces/710/.clang-format delete mode 100644 codeforces/713/.clang-format delete mode 100644 codeforces/719/.clang-format delete mode 100644 codeforces/725/.clang-format delete mode 100644 codeforces/731/.clang-format delete mode 100644 codeforces/734/.clang-format delete mode 100644 codeforces/739/.clang-format delete mode 100644 codeforces/744/.clang-format delete mode 100644 codeforces/748/.clang-format delete mode 100644 codeforces/753/.clang-format delete mode 100644 codeforces/756/.clang-format delete mode 100644 codeforces/760/.clang-format delete mode 100644 codeforces/762/.clang-format delete mode 100644 codeforces/764/.clang-format delete mode 100644 codeforces/776/.clang-format delete mode 100644 codeforces/780/.clang-format delete mode 100644 codeforces/784/.clang-format delete mode 100644 codeforces/786/.clang-format delete mode 100644 codeforces/787/.clang-format delete mode 100644 codeforces/790/.clang-format delete mode 100644 codeforces/797/.clang-format delete mode 100644 codeforces/799/.clang-format delete mode 100644 codeforces/805/.clang-format delete mode 100644 codeforces/806/.clang-format delete mode 100644 codeforces/811/.clang-format delete mode 100644 codeforces/817/.clang-format delete mode 100644 codeforces/820/.clang-format delete mode 100644 codeforces/827/.clang-format delete mode 100644 codeforces/834/.clang-format delete mode 100644 codeforces/835/.clang-format delete mode 100644 codeforces/839/.clang-format delete mode 100644 codeforces/847/.clang-format delete mode 100644 codeforces/849/.clang-format delete mode 100644 codeforces/855/.clang-format delete mode 100644 codeforces/859/.clang-format delete mode 100644 codeforces/863/.clang-format delete mode 100644 codeforces/867/.clang-format delete mode 100644 codeforces/871/.clang-format delete mode 100644 codeforces/874/.clang-format delete mode 100644 codeforces/878/.clang-format delete mode 100644 codeforces/881/.clang-format delete mode 100644 codeforces/886/.clang-format delete mode 100644 codeforces/888/.clang-format delete mode 100644 codeforces/891/.clang-format delete mode 100644 codeforces/894/.clang-format delete mode 100644 codeforces/895/.clang-format delete mode 100644 codeforces/898/.clang-format delete mode 100644 codeforces/900/.clang-format delete mode 100644 codeforces/903/.clang-format delete mode 100644 codeforces/905/.clang-format delete mode 100644 codeforces/909/.clang-format delete mode 100644 codeforces/913/.clang-format delete mode 100644 codeforces/916/.clang-format delete mode 100644 codeforces/918/.clang-format delete mode 100644 codeforces/920/.clang-format delete mode 100644 codeforces/923/.clang-format delete mode 100644 codeforces/925/.clang-format delete mode 100644 codeforces/927/.clang-format delete mode 100644 codeforces/928/.clang-format delete mode 100644 codeforces/929/.clang-format delete mode 100644 codeforces/933/.clang-format delete mode 100644 codeforces/935/.clang-format delete mode 100644 codeforces/937/.clang-format delete mode 100644 codeforces/938/.clang-format delete mode 100644 codeforces/943/.clang-format delete mode 100644 codeforces/944/.clang-format delete mode 100644 codeforces/946/.clang-format delete mode 100644 codeforces/950/.clang-format delete mode 100644 codeforces/952/.clang-format delete mode 100644 codeforces/954/.clang-format delete mode 100644 codeforces/957/.clang-format delete mode 100644 codeforces/962/.clang-format delete mode 100644 codeforces/964/.clang-format delete mode 100644 codeforces/966/.clang-format delete mode 100644 codeforces/970/.clang-format delete mode 100644 codeforces/971/.clang-format delete mode 100644 codeforces/974/.clang-format delete mode 100644 codeforces/981/.clang-format delete mode 100644 codeforces/988/.clang-format delete mode 100644 codeforces/993/.clang-format delete mode 100644 codeforces/995/.clang-format delete mode 100644 codeforces/996/.clang-format delete mode 100644 codeforces/998/.clang-format delete mode 100644 cses/dynamic-programming/.clang-format delete mode 100644 cses/graph-algorithms/.clang-format delete mode 100644 cses/introductory-problems/.clang-format delete mode 100644 cses/range-queries/.clang-format delete mode 100644 cses/sorting-and-searching/.clang-format delete mode 100644 kattis/11-02-2025/.clang-format delete mode 100644 kattis/18-2-2025/.clang-format delete mode 100644 kattis/25-2-2025/.clang-format delete mode 100644 usaco/bronze/simulation/.clang-format diff --git a/.gitignore b/.gitignore index 0296075..5ce1416 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ build io .clangd +.clang-format diff --git a/atcoder/042/.clang-format b/atcoder/042/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/atcoder/042/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1003/.clang-format b/codeforces/1003/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1003/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1006/.clang-format b/codeforces/1006/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1006/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1009/.clang-format b/codeforces/1009/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1009/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1013/.clang-format b/codeforces/1013/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1013/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1016/.clang-format b/codeforces/1016/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1016/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1017/.clang-format b/codeforces/1017/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1017/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1020/.clang-format b/codeforces/1020/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1020/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1027/.clang-format b/codeforces/1027/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/1027/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/1029/.clang-format b/codeforces/1029/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1029/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1032/.clang-format b/codeforces/1032/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1032/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1034/.clang-format b/codeforces/1034/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1034/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1037/.clang-format b/codeforces/1037/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1037/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1042/.clang-format b/codeforces/1042/.clang-format deleted file mode 100644 index d2c38f2..0000000 --- a/codeforces/1042/.clang-format +++ /dev/null @@ -1,5 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 4 -ColumnLimit: 100 -BreakBeforeBraces: Allman -PointerAlignment: Left diff --git a/codeforces/1043/.clang-format b/codeforces/1043/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/1043/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/1047/.clang-format b/codeforces/1047/.clang-format deleted file mode 100644 index d2c38f2..0000000 --- a/codeforces/1047/.clang-format +++ /dev/null @@ -1,5 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 4 -ColumnLimit: 100 -BreakBeforeBraces: Allman -PointerAlignment: Left diff --git a/codeforces/1059/.clang-format b/codeforces/1059/.clang-format deleted file mode 100644 index d2c38f2..0000000 --- a/codeforces/1059/.clang-format +++ /dev/null @@ -1,5 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 4 -ColumnLimit: 100 -BreakBeforeBraces: Allman -PointerAlignment: Left diff --git a/codeforces/1071/.clang-format b/codeforces/1071/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/1071/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/1074/.clang-format b/codeforces/1074/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/1074/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/17/.clang-format b/codeforces/17/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/17/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/19/.clang-format b/codeforces/19/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/19/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/431/.clang-format b/codeforces/431/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/431/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/479/.clang-format b/codeforces/479/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/479/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/498/.clang-format b/codeforces/498/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/498/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/506/.clang-format b/codeforces/506/.clang-format deleted file mode 100644 index b1ea9ab..0000000 --- a/codeforces/506/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 4 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/515/.clang-format b/codeforces/515/.clang-format deleted file mode 100644 index d2c38f2..0000000 --- a/codeforces/515/.clang-format +++ /dev/null @@ -1,5 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 4 -ColumnLimit: 100 -BreakBeforeBraces: Allman -PointerAlignment: Left diff --git a/codeforces/544/.clang-format b/codeforces/544/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/544/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/547/.clang-format b/codeforces/547/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/547/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/550/.clang-format b/codeforces/550/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/550/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/552/.clang-format b/codeforces/552/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/552/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/555/.clang-format b/codeforces/555/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/555/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/560/.clang-format b/codeforces/560/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/560/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/565/.clang-format b/codeforces/565/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/565/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/570/.clang-format b/codeforces/570/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/570/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/575/.clang-format b/codeforces/575/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/575/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/611/.clang-format b/codeforces/611/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/611/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/640/.clang-format b/codeforces/640/.clang-format deleted file mode 100644 index 5625628..0000000 --- a/codeforces/640/.clang-format +++ /dev/null @@ -1,2 +0,0 @@ -BasedOnStyle: Google -AllowShortFunctionsOnASingleLine: Empty diff --git a/codeforces/702/.clang-format b/codeforces/702/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/702/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/710/.clang-format b/codeforces/710/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/710/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/713/.clang-format b/codeforces/713/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/713/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/719/.clang-format b/codeforces/719/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/719/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/725/.clang-format b/codeforces/725/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/725/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/731/.clang-format b/codeforces/731/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/731/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/734/.clang-format b/codeforces/734/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/734/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/739/.clang-format b/codeforces/739/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/739/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/744/.clang-format b/codeforces/744/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/744/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/748/.clang-format b/codeforces/748/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/748/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/753/.clang-format b/codeforces/753/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/753/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/756/.clang-format b/codeforces/756/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/756/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/760/.clang-format b/codeforces/760/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/760/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/762/.clang-format b/codeforces/762/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/762/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/764/.clang-format b/codeforces/764/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/764/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/776/.clang-format b/codeforces/776/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/776/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/780/.clang-format b/codeforces/780/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/780/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/784/.clang-format b/codeforces/784/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/784/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/786/.clang-format b/codeforces/786/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/786/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/787/.clang-format b/codeforces/787/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/787/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/790/.clang-format b/codeforces/790/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/790/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/797/.clang-format b/codeforces/797/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/797/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/799/.clang-format b/codeforces/799/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/799/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/805/.clang-format b/codeforces/805/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/805/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/806/.clang-format b/codeforces/806/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/806/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/811/.clang-format b/codeforces/811/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/811/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/817/.clang-format b/codeforces/817/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/817/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/820/.clang-format b/codeforces/820/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/820/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/827/.clang-format b/codeforces/827/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/827/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/834/.clang-format b/codeforces/834/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/834/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/835/.clang-format b/codeforces/835/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/835/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/839/.clang-format b/codeforces/839/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/839/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/847/.clang-format b/codeforces/847/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/847/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/849/.clang-format b/codeforces/849/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/849/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/855/.clang-format b/codeforces/855/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/855/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/859/.clang-format b/codeforces/859/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/859/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/863/.clang-format b/codeforces/863/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/863/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/867/.clang-format b/codeforces/867/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/867/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/871/.clang-format b/codeforces/871/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/871/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/874/.clang-format b/codeforces/874/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/874/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/878/.clang-format b/codeforces/878/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/878/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/881/.clang-format b/codeforces/881/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/881/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/886/.clang-format b/codeforces/886/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/886/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/888/.clang-format b/codeforces/888/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/888/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/891/.clang-format b/codeforces/891/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/891/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/894/.clang-format b/codeforces/894/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/894/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/895/.clang-format b/codeforces/895/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/895/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/898/.clang-format b/codeforces/898/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/898/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/900/.clang-format b/codeforces/900/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/900/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/903/.clang-format b/codeforces/903/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/903/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/905/.clang-format b/codeforces/905/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/905/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/909/.clang-format b/codeforces/909/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/909/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/913/.clang-format b/codeforces/913/.clang-format deleted file mode 100644 index 59cd6f1..0000000 --- a/codeforces/913/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 2 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/916/.clang-format b/codeforces/916/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/916/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/918/.clang-format b/codeforces/918/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/918/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/920/.clang-format b/codeforces/920/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/920/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/923/.clang-format b/codeforces/923/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/923/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/925/.clang-format b/codeforces/925/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/925/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/927/.clang-format b/codeforces/927/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/927/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/928/.clang-format b/codeforces/928/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/928/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/929/.clang-format b/codeforces/929/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/929/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/933/.clang-format b/codeforces/933/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/933/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/935/.clang-format b/codeforces/935/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/935/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/937/.clang-format b/codeforces/937/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/937/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/938/.clang-format b/codeforces/938/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/938/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/943/.clang-format b/codeforces/943/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/943/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/944/.clang-format b/codeforces/944/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/944/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/946/.clang-format b/codeforces/946/.clang-format deleted file mode 100644 index cbec8b9..0000000 --- a/codeforces/946/.clang-format +++ /dev/null @@ -1,4 +0,0 @@ -BasedOnStyle: Google -IndentWidth: 2 -ColumnLimit: 100 -PointerAlignment: Left diff --git a/codeforces/950/.clang-format b/codeforces/950/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/950/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/952/.clang-format b/codeforces/952/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/952/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/954/.clang-format b/codeforces/954/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/954/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/957/.clang-format b/codeforces/957/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/957/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/962/.clang-format b/codeforces/962/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/962/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/964/.clang-format b/codeforces/964/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/964/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/966/.clang-format b/codeforces/966/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/966/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/970/.clang-format b/codeforces/970/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/970/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/971/.clang-format b/codeforces/971/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/971/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/974/.clang-format b/codeforces/974/.clang-format deleted file mode 100644 index 5625628..0000000 --- a/codeforces/974/.clang-format +++ /dev/null @@ -1,2 +0,0 @@ -BasedOnStyle: Google -AllowShortFunctionsOnASingleLine: Empty diff --git a/codeforces/981/.clang-format b/codeforces/981/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/981/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/988/.clang-format b/codeforces/988/.clang-format deleted file mode 100644 index 99733d1..0000000 --- a/codeforces/988/.clang-format +++ /dev/null @@ -1,17 +0,0 @@ -BasedOnStyle: LLVM -IndentWidth: 4 -UseTab: Never - -AllowShortIfStatementsOnASingleLine: Never -AllowShortLoopsOnASingleLine: false -AllowShortFunctionsOnASingleLine: None -AllowShortLambdasOnASingleLine: None -AllowShortBlocksOnASingleLine: Never -AllowShortEnumsOnASingleLine: false -AllowShortCaseExpressionOnASingleLine: false - -BreakBeforeBraces: Attach -ColumnLimit: 100 -AlignAfterOpenBracket: Align -BinPackArguments: false -BinPackParameters: false diff --git a/codeforces/993/.clang-format b/codeforces/993/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/993/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/995/.clang-format b/codeforces/995/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/995/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/996/.clang-format b/codeforces/996/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/996/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/codeforces/998/.clang-format b/codeforces/998/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/codeforces/998/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/cses/dynamic-programming/.clang-format b/cses/dynamic-programming/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/cses/dynamic-programming/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/cses/graph-algorithms/.clang-format b/cses/graph-algorithms/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/cses/graph-algorithms/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/cses/introductory-problems/.clang-format b/cses/introductory-problems/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/cses/introductory-problems/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/cses/range-queries/.clang-format b/cses/range-queries/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/cses/range-queries/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/cses/sorting-and-searching/.clang-format b/cses/sorting-and-searching/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/cses/sorting-and-searching/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/kattis/11-02-2025/.clang-format b/kattis/11-02-2025/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/kattis/11-02-2025/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/kattis/18-2-2025/.clang-format b/kattis/18-2-2025/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/kattis/18-2-2025/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/kattis/25-2-2025/.clang-format b/kattis/25-2-2025/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/kattis/25-2-2025/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false diff --git a/usaco/bronze/simulation/.clang-format b/usaco/bronze/simulation/.clang-format deleted file mode 100644 index e7350c4..0000000 --- a/usaco/bronze/simulation/.clang-format +++ /dev/null @@ -1,9 +0,0 @@ -BasedOnStyle: Google -AllowShortBlocksOnASingleLine: false -AllowShortCaseLabelsOnASingleLine: false -AllowShortCompoundRequirementOnASingleLine: false -AllowShortEnumsOnASingleLine: false -AllowShortFunctionsOnASingleLine: false -AllowShortIfStatementsOnASingleLine: false -AllowShortLambdasOnASingleLine: false -AllowShortLoopsOnASingleLine: false From 390ffa1e1c80bf2ed439242ccd866a3c0d7566b8 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Mon, 2 Feb 2026 12:47:09 -0500 Subject: [PATCH 10/10] misc files --- codeforces/1070/a.cc | 58 +++++++++++++++++++++++++++++++++++++++++++ codeforces/1073/a.cc | 58 +++++++++++++++++++++++++++++++++++++++++++ codeforces/1073/b1.cc | 58 +++++++++++++++++++++++++++++++++++++++++++ codeforces/1074/e.cc | 2 ++ codeforces/1074/f.cc | 58 +++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 234 insertions(+) create mode 100644 codeforces/1070/a.cc create mode 100644 codeforces/1073/a.cc create mode 100644 codeforces/1073/b1.cc create mode 100644 codeforces/1074/f.cc diff --git a/codeforces/1070/a.cc b/codeforces/1070/a.cc new file mode 100644 index 0000000..dc8702a --- /dev/null +++ b/codeforces/1070/a.cc @@ -0,0 +1,58 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> t; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/codeforces/1073/a.cc b/codeforces/1073/a.cc new file mode 100644 index 0000000..805d4f6 --- /dev/null +++ b/codeforces/1073/a.cc @@ -0,0 +1,58 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/codeforces/1073/b1.cc b/codeforces/1073/b1.cc new file mode 100644 index 0000000..805d4f6 --- /dev/null +++ b/codeforces/1073/b1.cc @@ -0,0 +1,58 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}} diff --git a/codeforces/1074/e.cc b/codeforces/1074/e.cc index 7506375..42ab639 100644 --- a/codeforces/1074/e.cc +++ b/codeforces/1074/e.cc @@ -36,6 +36,7 @@ template constexpr T MAX = std::numeric_limits::max(); void solve() { u32 n, m, k; + string s; cin >> n >> m >> k; @@ -49,6 +50,7 @@ void solve() { cin >> b[i]; } + cin >> s; } int main() { // {{{ diff --git a/codeforces/1074/f.cc b/codeforces/1074/f.cc new file mode 100644 index 0000000..805d4f6 --- /dev/null +++ b/codeforces/1074/f.cc @@ -0,0 +1,58 @@ +#include // {{{ + +#include +#ifdef __cpp_lib_ranges_enumerate +#include +namespace rv = std::views; +namespace rs = std::ranges; +#endif + +#pragma GCC optimize("O2,unroll-loops") +#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") + +using namespace std; + +using i32 = int32_t; +using u32 = uint32_t; +using i64 = int64_t; +using u64 = uint64_t; +using f64 = double; +using f128 = long double; + +#if __cplusplus >= 202002L +template +constexpr T MIN = std::numeric_limits::min(); + +template +constexpr T MAX = std::numeric_limits::max(); +#endif + +#ifdef LOCAL +#define db(...) std::print(__VA_ARGS__) +#define dbln(...) std::println(__VA_ARGS__) +#else +#define db(...) +#define dbln(...) +#endif +// }}} + +void solve() { + +} + +int main() { // {{{ + std::cin.exceptions(std::cin.failbit); +#ifdef LOCAL + std::cerr.rdbuf(std::cout.rdbuf()); + std::cout.setf(std::ios::unitbuf); + std::cerr.setf(std::ios::unitbuf); +#else + std::cin.tie(nullptr)->sync_with_stdio(false); +#endif + u32 tc = 1; + std::cin >> tc; + for (u32 t = 0; t < tc; ++t) { + solve(); + } + return 0; +} // vim: set foldmethod=marker foldmarker={{{,}}}