26 April 2020

Bugforces (ft Education Codeforces Round 86)

Consider the following implementation to find the smallest multiple of x at least as big as y:

typedef long long i64;

i64
next_mult_ge(const i64 y, const i64 x)
{
    return ceil(y / (double) x) * x;
}

What can go wrong?

Educational Codeforces Round 86 Postmortem

What went well
  • Sampling other submissions, my solution to C is cleaner and more intuitive (if only it worked!!!)
What went poorly
  • A took a long time
  • My C implementation died to nuances of ceil(); I wanted to find the multiple of a number at least as large as some threshold.
Where I got lucky
  • I was able to use fast-slow testing to determine a test case that breaks my C.

25 April 2020

TopCoder SRM 784 Postmortem

What went well
  • I was able to solve Div2C/Div1A.
  • I was able to fix a bug in my implementation for C.
What went poorly
  • Got A wrong because I couldn't understand the problem.
  • I realized the bug in my C after submitting my code, so the resubmission incurred a significant (200pt) penalty).
Where I got lucky
  •  Div2C/Div1A seemed a lot easier than usual.

14 April 2020

Codeforces Round #635 (Div. 2) Postmortem

What went well
  • A was trivial.
  • B was easy.
  • I didn't feel stuck when attempting D.
What went poorly
  • C took a long time because I didn't realize that I had to consider two criteria for the greedy solution (first Wrong Answer). Then I didn't realize that the two criteria were not mutually exclusive (second Wrong Answer). All said and done, I spent 1h30.
Where I got lucky
  • Somehow still above 1700!

06 April 2020

CA-1 Drive: Short Version

Start: CA-1 exit off US-101
First choice: CA-1 (orange) or Panoramic Drive (red)
Second choice: Petaluma (blue) or Santa Rosa (green)
  • There's a great restaurant in Santa Rosa called "Naked Pig." They serve the lightest waffles with optional bacon bits embedded.
Return: US-101 South