Sunday, January 2, 2022

競プロ典型 90 問

 ★2

004 - Cross Sum(★2) (atcoder.jp) [pre-processing the sum of each row and column]

022 - Cubic Cake(★2) (atcoder.jp) [find gcd=g of all side, and calculate the num of cuts to make g-sided cubes ]

024 - Select +/- One(★2) (atcoder.jp) [k should be equal or greater than sum of diffs, and reminder should be even]




055 - Select 5(★2) (atcoder.jp) [brute force, const opt]

078 - Easy Graph Problem(★2) (atcoder.jp) [tracking nodes' state in array]


★3


038 - Large LCM(★3) (atcoder.jp) [lcm, gcd, formula transformation]

046 - I Love 46(★3) (atcoder.jp) [mod hash array, counting]




044 - Shift and Swapping(★3) (atcoder.jp) [keep track of shift number, us it as offset]

007 - CP Classes(★3) (atcoder.jp) [upper_bound, lower_bound]

020 - Log Inequality(★3) (atcoder.jp) [long long int, log formula transformation]

032 - AtCoder Ekiden(★3) [next_permutation, set, brute-force + pruning]



076 - Cake Cut(★3) (atcoder.jp) [2 pointers, Caterpillar method]

075 - Magic For Balls(★3) (atcoder.jp) [Factorization prime divisors]



079 - Two by Two(★3) (atcoder.jp) [greedy, flipping from top left corner]


082 - Counting Numbers(★3) (atcoder.jp) [calculate answer for each digit length]

018 - Statue of Chokudai(★3) (atcoder.jp) [geometry, triangle, sin, cos, arctan]


★4








070 - Plant Planning(★4) (atcoder.jp) [Manhattan dist, find median]




085 - Multiplication 085(★4) (atcoder.jp) [divisor factoring, backtracking]



★5

029 - Long Bricks(★5) (atcoder.jp) [Simulate by using range set/range max segtree]


056 - Lucky Bag(★5) (atcoder.jp) [knapsack dp, sub sum problem]


013 - Passing(★5) (atcoder.jp) [Dijksra from start and end node]


060 - Chimera(★5) (atcoder.jp) [Do LIS twice from left & right side]

087 - Chokudai's Demand(★5) (atcoder.jp) [Use binary search to find upper & lower bound + Floyd-Warshall]


051 - Typical Shop(★5) (atcoder.jp) [meet-in-the-middle, binary search]



030 - K Factors(★5) (atcoder.jp) [Sieve Of Eratosthenes, prime factoring]

037 - Don't Leave the Spice(★5) (atcoder.jp) [Knapsack like dp optimized by RangeMax SegTree]

066 - Various Arrays(★5) (atcoder.jp) [Linearity of expectation, probability]

086 - Snuke's Favorite Arrays(★5) (atcoder.jp) [Bit partitioning, combinatorics, bit-brute force]

068 - Paired Information(★5) (atcoder.jp) [UnionFind, Set, Pre-processing queries]


★6

019 - Pick Two(★6) (atcoder.jp) [range dp, interval dp]

045 - Simple Grouping(★6) (atcoder.jp) [bitDP, nested subset loop O(3^n)]

062 - Paint All(★6) (atcoder.jp) [Simulate in reverse order of operations]

083 - Colorful Graph(★6) (atcoder.jp) [Sqrt decomposotion, split deg>=B, deg<B nodes]

054 - Takahashi Number(★6) (atcoder.jp) [Reduce edge number by changing graph]

080 - Let's Share Bit(★6) (atcoder.jp) [Combinatorics, inclusion & exclusion principle, bit operations]

015 - Don't be too close(★6) (atcoder.jp) [Combinatorics, nCk, Harmonic series = O(logN)]

011 - Gravy Jobs(★6) (atcoder.jp) [dp[i][j] - i days and j jobs ans, process jobs in deadline order]

031 - VS AtCoder(★6) [grundy, dp[i][j] - i blue & j white state grundy number]

088 - Similar but Different Ways(★6) (atcoder.jp) [Pigeonhole Principle, dfs + pruning]

009 - Three Point Angle(★6) (atcoder.jp) [drift angle, atan2, geometry]

049 - Flip Digits 2(★6) (atcoder.jp) [Interval Flipping, converting to graph, MST, UnionFind]

057 - Flip Flap(★6) (atcoder.jp) [Matrix rank, Gaussian method, Elimination method]

074 - ABC String 2(★6) (atcoder.jp) [Ad-hoc, Experiment, Potential, Semi-Invariant, 2^60=10^18]


★7

023 - Avoid War(★7) (atcoder.jp) [BitDP, Profiling, State Elimination]

077 - Planes on a 2D Plane(★7) (atcoder.jp) [Max Flow, Bipartite max matching, Find match]

047 - Monochromatic Diagonal(★7) (atcoder.jp) [String modification RGB->012, Rolling-hash]

005 - Restricted Digits(★7) (atcoder.jp) [Digit DP, doubling, pow matrix]

017 - Crossing Segments(★7) (atcoder.jp) [BIT, counting left/right ends]

089 - Partitions and Inversions(★7) (atcoder.jp) [DP, 2 pointers, BIT, index compression]




025 - Digit Product Equation(★7) (atcoder.jp) [dfs, prime divisors, brute-force]

035 - Preserve Connectivity(★7) (atcoder.jp) [Euler tour, lca, dfs, auxillary tree]



No comments:

Post a Comment