Hello Codeforces! Today I feel like thirsty for contribution, so I'll share some trick to get (almost) unlimited amount of (almost) square grid paper during contest, and hope that I will get some contribution.
If you use Vim, open an empty file and type the following from normal mode:
i+<esc>25A---+<esc>
o|<esc>25A |<esc>
ggVGyG35pGdd
Then you will get this:
The Vim commands are basically just doing the copy-and-paste part for you. If you don't use Vim, you can manually produce the pattern instead.
The grid is 101 characters wide * 71 characters high, or 25 cells wide * 35 cells high. 101 * 71 characters roughly matches domjudge's upper limit for printing, but please test it in testing session. This trick has been tested in 2023 Taoyuan regional, and the staff have approved this trick.
Since the grid cells are (almost) square, you can use them in DP and Geometry problems. Happy printing!
P.S. Please don't print more than you need. Some people got warning from juries for printing 10+ pages of grid paper during testing session.
Some vim golf, your last line can be replaced with this, saving some keystrokes :0
Are we playing vimgolf?
I guess we are playing vimgolf!
My original solution: 30
Your solution: 29
My solution: 27
Ah yes vimgolf!
One key less:
I'm confused, why don't you just use scrap paper
Because they are not like a grid
God-tier blog
I'm confused, why don't you bring grid paper with you beforehand
I am confused , why not just draw some horizontal lines and vertical lines on a whiteboard!!
Some regionals (e.g. Taoyuan) don't let contestants bring extra paper, so we might have to sacrifice some spaces in our codebook if we want to bring pre-printed grid paper.
Oh so there are some constraints e.g. 20 pages at most? Then that's understandable.
I think I'm the only person who use Excel for visualizing dp :)