i am just grinding a problem ( https://mirror.codeforces.com/contest/1991/problem/C ) and i found that this problem is bit different and how can someone came to this idea. is, this types of patterns repeats or it something else. bit confused...someone help