April Fools Day Contest 2022 Editorial

Правка en15, от Agnimandur, 2022-04-01 18:56:20

All problems were prepared by me and magnus.hegdahl. Thanks to BucketPotato and Monogon for valuable feedback and testing. Special thanks to MikeMirzayanov for the comingh up with the idea and preparing the unique checker for 1663H - Cross-Language Program. I hope you enjoyed the contest.

Example Python code written by Agnimandur is provided for each problem.

1663A - Who Tested?

Clue 1
Clue 2
Solution
Solution Code

1663B - Mike's Sequence

Clue 1
Clue 2
Clue 3
Solution

Solution Code

1663C - Pōja Verdon

Clue 1

Clue 2

Solution

pōja means their and verdon means sum (or amount based on context) in High Valyrian (you can easily translate this on Duolingo).

In a nutshell: Print the sum of the array.

1663D - Is it rated - 3

Clue 1

Clue 2

Solution

The problem is asking whether the Atcoder contest (ABC,ARC,AGC) is rated for a rating $$$X$$$. (Note that the judge ignores Atcoder heuristic contests for simplicity).

  • ABC's are rated for $$$[0,1999]$$$
  • ARC's are rated for $$$[0,2799]$$$
  • AGC's are rated for $$$[1200,\infty]$$$

1663E - Are You Safe?

Clue 1

Clue 2

Solution

The problem is just a word search (horizontal, vertical, diagonal) for theseus. You should only go in the forward direction when you search for a word.

Bonus Clues (for other problems)

There are also some red herring words out there.

1663F - In Every Generation...

Clue 1

Clue 2

Clue 3

Solution

Perhaps you notice the lengths of the words buffy, the, vampire, slayer are unique integers in the set {3,5,6,7}.

Given the string $$$s$$$, simply "add" that string with the target word of the same length.

Here's how adding two letters work:

  1. Convert both letters to numbers in $$$[0,25]$$$.
  2. Add the two numbers up modulo 26.
  3. Convert the number back into a letter.

You can verify your addition algorithm is correct by checking whether "tourist" + "vampire" = "ooggqjx" (as provided in the sample).

Finally, if the length of $$$s$$$ is $$$4$$$, the answer is "none", because there is no word of length 4 in Buffy the Vampire Slayer.

1663G - Six Characters

Clue 1

Clue 2

Clue 3

Solution

The six characters is a pun: the input is a string of length 6 like "abcdef", but the output is a string \textit{consisting} of only 6 characters: [ ] ( ) ! +.

Brief research will demonstrate a mapping from each english letter to a JSFuck string. Two letters can be concatenated with "+".Note that the optimal mapping will make your solution file approximately 12KB in size, well within the 64KB requirement of Codeforces.

However, the mapping from each letter to javascript is not unique! However, the legend mentions that Aenar needs to go to the string's "home". JSFuck's home website is here, which is where the jury's mapping is created from.

1663H - Cross-Language Program

Solution

// \
begin end.
int main() {}
Теги april 1st, april fools day contest, agnimandur

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en23 Английский Agnimandur 2022-04-01 20:01:33 125
en22 Английский Agnimandur 2022-04-01 19:35:34 0 (published)
en21 Английский Agnimandur 2022-04-01 19:33:58 107
en20 Английский Agnimandur 2022-04-01 19:31:35 970 Tiny change: '< "NO";\n}~~~~~\n\n\n</spoi' -> '< "NO";\n}\n~~~~~\n\n</spoi'
en19 Английский Agnimandur 2022-04-01 19:16:49 2 Tiny change: '2393980]\nAlgorith' -> '2393980]\n\nAlgorith'
en18 Английский Agnimandur 2022-04-01 19:16:10 301
en17 Английский Agnimandur 2022-04-01 19:08:52 459
en16 Английский Agnimandur 2022-04-01 19:02:44 536 Tiny change: ')\n~~~~~\n\n### [p' -> ')\n~~~~~\n</spoiler>\n\n### [p'
en15 Английский Agnimandur 2022-04-01 18:56:20 4
en14 Английский Agnimandur 2022-04-01 18:49:36 321 Tiny change: 'Code">\n\n~~~~~python\nprint("b' -> 'Code">\n\npython~~~~~\nprint("b'
en13 Английский Agnimandur 2022-04-01 18:44:47 112
en12 Английский Agnimandur 2022-04-01 18:43:15 327
en11 Английский Agnimandur 2022-04-01 18:38:21 232 Tiny change: 'm:1663H]\n\nCredit t' -> 'm:1663H]\nCredit t'
en10 Английский Agnimandur 2022-04-01 18:36:33 313
en9 Английский Agnimandur 2022-04-01 18:34:36 16
en8 Английский Agnimandur 2022-04-01 18:33:36 1286
en7 Английский Agnimandur 2022-04-01 18:28:07 875
en6 Английский Agnimandur 2022-04-01 18:25:32 925
en5 Английский Agnimandur 2022-04-01 18:23:32 702
en4 Английский Agnimandur 2022-04-01 18:20:59 53
en3 Английский Agnimandur 2022-04-01 18:20:04 841
en2 Английский Agnimandur 2022-04-01 18:16:53 616
en1 Английский Agnimandur 2022-04-01 18:12:22 758 Initial revision (saved to drafts)