The girl Umka loves to travel and participate in math olympiads. One day she was flying by plane to the next olympiad and out of boredom explored a huge checkered sheet of paper. Denote thenn-th Fibonacci number asFn=⎧⎩⎨1,1,Fn−2+Fn−1,n=0;n=1;n≥2.Fn={1,n=0;1,n...
She then received a 2 and decided to write it in the 1st sheet. Then she received a 1 and wrote it in the 2nd sheet. At last, she received a 3 and replaced 1 with 3 in the 2nd sheet. At this time all the sheets were filled with a number and they were non-decreasing, so she...
C. White Sheet 题目链接:https://codeforces.com/contest/1216/problem/C 题目大意:给你两个黑色矩形和一个白色矩形的左下和右上角的坐标,问你白色矩形是否能够完全被黑色矩形覆盖 解题思路:如果白色矩形能够被黑色矩形完全覆盖,则白色矩形边上的所有点都在黑色矩形之内,因此我们可以考虑遍历 白色边上的所有点,但...
2. [1763C] - Another Array Problem Rating:2000 Status:Hint + Data Evaluate:Medium 注意到如下的观察: 观察: 对于任意一个\(i\in(2,n]\)的\(i\),存在一种方法将子序列\([1,i]\)全部赋值成\(a_i\) 首先连续操作\([1,2]\):\((a_1,a_2) \to(|a_1-a_2|,|a_1-a_2|)\to(0,...
http://codeforces.com/contest/1118/problem/D1 http://codeforces.com/contest/1118/problem/D2 题意:有n杯咖啡,m张作业,没杯咖啡有能量点a[i],一点能量能做一张作业,同一天喝多杯能量会减少:第一杯a[i],第二杯max(0,a[i]-1),第三杯max(0,a[i]-2)...;问完成m张...猜你...
DSA (Level Up + Interview Prep) Sheet.xlsx Updated May 11, 2024 Personal (CP- Practise).xlsx Updated May 11, 2024 README.md Update README.md May 11, 2024 Repository files navigation README Problem Solving This repository contains the problems I solved on LeetCode, GeeksforGeeks, Interview...
1617 D2 - RPD and Rap Sheet (Hard Version) GNU C++17 brute force constructive algorithms interactive math *2200 Sep/03/2021 21:41 1616 C - Need for Pink Slips GNU C++17 bitmasks brute force dfs and similar implementation math probabilities *1900 Sep/03/2021 18:25 1615 D1 - RPD and ...
A. Noldbach problem time limit per test 2 seconds memory limit per test 64 megabytes input standard input output standard output Nick is interested in prime numbers. Once he read aboutGoldbach problem. It states that every even integer greater than2can be expressed as the sum of two primes....
The extension updates a Google Sheet with details like time taken, date, submission link, problem details, rating, tags, and your personal remarks. You can add the Google Sheet at the time of installation and change it anytime as per your convenience. Local Data Storage: Your progress data ...
Vika has an infinite sheet of squared paper. Initially all squares are white. She introduced a two-dimensional coordinate system on this sheet and drew n black horizontal and vertical segments parallel to the coordinate axes. All segments have width equal to 1 square, that means every segment ...