tag:blogger.com,1999:blog-7126341455752435052020-04-26T13:32:56.792-04:00Doesn't ExistThis blog does not exist. || Blog of shewu.mecherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.comBlogger298125tag:blogger.com,1999:blog-712634145575243505.post-79236242076210542952020-04-26T13:16:00.001-04:002020-04-26T13:32:56.735-04:00Bugforces (ft Education Codeforces Round 86)Consider the following implementation to find the smallest multiple of x at least as big as y:<br /><br /><pre style="border: 1px solid black;">typedef long long i64;<br /><br />i64<br />next_mult_ge(const i64 y, const i64 x)<br />{<br /> return ceil(y / (double) x) * x;<br />}<br /></pre><br />What can go wrong?<img src="http://feeds.feedburner.com/~r/DoesntExist/~4/PU4BnSrlw1w" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/04/bugforces-ft-education-codeforces-round.htmltag:blogger.com,1999:blog-712634145575243505.post-28664830404182208462020-04-26T13:11:00.000-04:002020-04-26T13:30:45.514-04:00Educational Codeforces Round 86 PostmortemWhat went well<br /><ul><li>Sampling other submissions, my solution to C is cleaner and more intuitive (if only it worked!!!)</li></ul>What went poorly<br /><ul><li>A took a long time</li><li>My C implementation died to nuances of ceil(); I wanted to find the multiple of a number at least as large as some threshold.</li></ul>Where I got lucky<br /><ul><li>I was able to use fast-slow testing to determine a test case that breaks my C. </li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/l1XhBllI8Bk" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/04/educational-codeforces-round-86.htmltag:blogger.com,1999:blog-712634145575243505.post-73784067539935357522020-04-25T13:40:00.002-04:002020-04-25T13:40:24.264-04:00TopCoder SRM 784 PostmortemWhat went well<br /><ul><li>I was able to solve Div2C/Div1A.</li><li>I was able to fix a bug in my implementation for C.</li></ul>What went poorly<br /><ul><li>Got A wrong because I couldn't understand the problem.</li><li>I realized the bug in my C after submitting my code, so the resubmission incurred a significant (200pt) penalty).</li></ul>Where I got lucky<br /><ul><li> Div2C/Div1A seemed a lot easier than usual.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/tlmWJmzFOXk" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/04/topcoder-srm-784-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-40317569241908553982020-04-14T21:34:00.000-04:002020-04-16T13:24:23.587-04:00Codeforces Round #635 (Div. 2) PostmortemWhat went well<br /><ul><li>A was trivial.</li><li>B was easy.</li><li>I didn't feel stuck when attempting D. </li></ul>What went poorly<br /><ul><li>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.</li></ul>Where I got lucky<br /><ul><li>Somehow still above 1700!</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/uhgwUkcjQRI" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/04/codeforces-round-635-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-46641645897312810922020-04-06T23:00:00.002-04:002020-04-06T23:00:12.686-04:00CA-1 Drive: Short Version<div class="separator" style="clear: both; text-align: center;"><a href="https://1.bp.blogspot.com/-9A_86umRx3I/XovMADg-fNI/AAAAAAAAF_c/pPN2MDvrfqALORN_8ZpWKr5trCnkFVoBQCLcBGAsYHQ/s1600/pch_short.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1562" data-original-width="1339" height="640" src="https://1.bp.blogspot.com/-9A_86umRx3I/XovMADg-fNI/AAAAAAAAF_c/pPN2MDvrfqALORN_8ZpWKr5trCnkFVoBQCLcBGAsYHQ/s640/pch_short.png" width="547" /></a></div>Start: CA-1 exit off US-101<br />First choice: CA-1 (orange) or Panoramic Drive (red)<br />Second choice: Petaluma (blue) or Santa Rosa (green)<br /><ul><li>There's a great restaurant in Santa Rosa called "Naked Pig." They serve the lightest waffles with optional bacon bits embedded.</li></ul>Return: US-101 South <img src="http://feeds.feedburner.com/~r/DoesntExist/~4/HpeG6tshQgU" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/04/ca-1-drive-short-version.htmltag:blogger.com,1999:blog-712634145575243505.post-13075862271682757142020-03-03T23:12:00.002-05:002020-03-03T23:12:35.296-05:00Codeforces Ozon Tech Challenge (Div. 1 + Div. 2) PostmortemWhat went well<br /><ul><li>C was a silly number theory problem, which I got in ~10 minutes. This might be my fastest C solve yet.</li></ul>What went wrong<br /><ul><li>I was unable to debug my solution to D in ~2 hours. I initially started pursuing an idea which involved querying vertices from pairs of vertices, but then I wasn't sure which two of the (up to) four vertices I should query. Then I noticed that I can just "trim the tree" by querying two leaves at once and pruning the tree if the LCA were neither leaves queried. However, I overcomplicated my solution by removing the vertices in the path from the leaf to the LCA, so I'm sure the bug is somewhere in there.</li><li>I wasn't sure how to prove B, which took me 20 minutes to solve.</li></ul>Where I got lucky<br /><ul><li>I gained elo so my rating is back above 1700. Yay! </li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/0LkKeT12Sjo" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/03/codeforces-ozon-tech-challenge-div-1.htmltag:blogger.com,1999:blog-712634145575243505.post-35314649095079506752020-01-30T23:00:00.001-05:002020-01-30T23:00:04.761-05:00Educational Codeforces Round 81 PostmortemWhat went well<br /><ul><li>If I had actually solved 4 problems, I would have gained over 100 elo…</li><li>I solved D, which was a number theory problem. (Nick missed this problem; muahahaha)</li></ul>What went wrong<br /><ul><li>My impure thoughts on problem B died on system test #11. Since I passed all 10 pretests, I didn't think to revisit my solution and verify with fast-slow testing.</li><li>I took a long time to recognize the totient function. My first reaction was "some inclusion-exclusion counting" upon realizing a pattern from my scratch work. Then I needed two tries to code a fast (sqrt N) totient function.</li></ul> Where I got lucky<br /><ul><li>Everyone else died on B. Turns out it is rated 1800. </li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/Nn1I4OriK0I" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/01/educational-codeforces-round-81.htmltag:blogger.com,1999:blog-712634145575243505.post-90090953262696086912020-01-19T22:54:00.000-05:002020-01-30T22:54:24.810-05:00Codeforces Round #614 (Div. 2) PostmortemWhat went well<br /><ul><li>A was a fast 3-minute problem.</li><li>B was easy and I solved it decently quickly in 9 minutes.</li></ul>What went wrong<br /><ul><li>C took way too long to code, mainly because I didn't have a good representation on blocking either diagonal path. Turns out that if cell (r, c) is blocked, then I just needed to check (1-r, c-1), (1-r, c), and (1-r, c+1). Furthermore, if I used a 2x(N+2) grid instead of 2xN grid, then I wouldn't have to do any bounds checking because the (*, -1) and (*, N) cells could never be set.</li></ul>Where I got lucky<br /><ul><li> I didn't do so terribly so as to get demoted to green.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/umbyge_9yzA" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/01/codeforces-round-614-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-48528158783804036392020-01-16T22:48:00.000-05:002020-01-30T22:49:33.488-05:00TopCoder SRM 775 (Div. 2) PostmortemWhat went well<br /><ul><li>My TopCoder career is off to a good start! I solved A and B for +199 rating, which puts me midway through blue (1300-1499).</li></ul>What went wrong<br /><ul><li>I apparently failed to understand A, so wasted 5 minutes implementing something else. </li><li>I was rusty on floodfill and took 40 minutes to solve B, where 30 minutes was debugging.</li></ul>Where I got lucky<br /><ul><li>I'm decently quick on easy problems, which luckily A and B were.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/NpDWLWYrhPA" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/01/topcoder-srm-775-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-64256169979968975012020-01-14T22:43:00.000-05:002020-01-30T22:44:08.371-05:00Educational Codeforces Round 80 PostmortemWhat went well<br /><ul><li>The contest was so hard that I really wanted to quit after reading A, but persevered to the end. Somehow I solved three problems…</li></ul>What went poorly<br /><ul><li>I'm terrible with floors and ceilings. I'm also apparently bad at quickly recognizing monotonic functions.</li><li>I'm also bad at bijecting problems; I did not recognize during the contest that C was asking for a monotonically increasing sequence of length 2n, rather than two sequences of length n with weird constraints on elements.</li></ul>Where I got lucky<br /><ul><li>Solving three problems with a high penalty only cost 8 elo.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/r4miM2egdY4" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/01/educational-codeforces-round-80.htmltag:blogger.com,1999:blog-712634145575243505.post-4457330741829289562020-01-10T23:42:00.003-05:002020-01-10T23:43:34.723-05:00Codeforces Round #613 (Div. 2) PostmortemLink to contest <a href="https://codeforces.com/contest/1285">here</a><br /><br />What went well<br /><ul><li>I found a most elegant solution to B: much more elegant than the editorial.</li><li>I figured out D, a bits (bitmasks?) problem! I think I'm really weak at bits and xors.</li></ul>What went wrong<br /><ul><li>B took ~50 minutes and two wrong submissions.</li></ul>Where I got lucky<br /><ul><li>I had to think a little for A to prove correctness, but end-to-end latency still only took 3 minutes.</li><li>I submitted C without proving correctness and got it right??! Lucky me!</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/DZ38SfWxtDE" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/01/codeforces-round-613-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-17767824364525368682020-01-06T21:20:00.001-05:002020-01-06T21:32:20.701-05:00McLaren 600LT Spider First Impressions<i>Author's note: This test drive was done in April 2019, but I have been procrastinating with publishing this post. In any case, enjoy!</i><br /><br />I had the opportunity to drive a 2020 McLaren 600LT Spider at McLaren of San Francisco! I never got a chance to test drive a 600LT couple since their debut last year, nor have I gotten a chance to test drive a 570S Spider that I so dear wanted once upon a time. Unfortunately, the test drive happened during mid-day on a weekday, which wasn't the best time to tour back roads.<br /><br /><div class="separator" style="clear: both; text-align: center;"><a href="https://1.bp.blogspot.com/-RUgMo-qXDCI/XhPqHMSnu1I/AAAAAAAAF2U/Cy9dj9BD6mg4SyHrYpDcIPgseosqsTMKgCEwYBhgL/s1600/2019-04-26%2B12.32.32.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1200" data-original-width="1600" height="240" src="https://1.bp.blogspot.com/-RUgMo-qXDCI/XhPqHMSnu1I/AAAAAAAAF2U/Cy9dj9BD6mg4SyHrYpDcIPgseosqsTMKgCEwYBhgL/s320/2019-04-26%2B12.32.32.jpg" width="320" /></a></div><br />600LT specific comments:<br /><ul><li>No creep! This is important to me because I struggle with chauffeur braking in automatic transmission cars. On that note, I also appreciate that Tesla provides a no-creep option.</li><li>Same great hydraulic steering is considerably heavier than in the 570S and 570GT, especially in "track" handling mode.</li><li>The gunshot/whip crack downshifts are not a lie. They are incredible to experience with the top down.</li><li>No flames were to be seen during mild street driving in daylight :-(</li><li>I feel like the LT cars have stiffer (or just solid) engine mounts. I felt a massage from the seat while sitting at a red light.</li><li>No comment on the upgraded brakes; they were fine for street use. No comment on comparing the upgraded system from the 720S to the normal ceramics on the 570S or to the steel brakes in the 570GT.</li><li>No comment on the lighter weight. Need to hit the back roads or track…</li><li>No comment on downforce from its cute little fixed wing. Definitely need to push a bit on the track for that.</li><li>The normal power seats didn't go as far forward in this 600LT as I thought they would. Speaking of normal power seats…</li><li>This test car didn't have the critically-acclaimed Senna seats! I think that the dealer has a second demo Spider with the Senna seats. I hope I can take that car for a proper spin!</li></ul><div class="separator" style="clear: both; text-align: center;"></div><div class="separator" style="clear: both; text-align: center;"></div><div class="separator" style="clear: both; text-align: center;"></div><div class="separator" style="clear: both; text-align: center;"><a href="https://1.bp.blogspot.com/-tjTgUEZUhwQ/XhPqHtx3ZaI/AAAAAAAAF2U/Uwso9h6Q_QMzowDWggkkmXHO05lpPAmZACEwYBhgL/s1600/2019-04-26%2B12.33.03.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1600" data-original-width="1200" height="320" src="https://1.bp.blogspot.com/-tjTgUEZUhwQ/XhPqHtx3ZaI/AAAAAAAAF2U/Uwso9h6Q_QMzowDWggkkmXHO05lpPAmZACEwYBhgL/s320/2019-04-26%2B12.33.03.jpg" width="240" /></a></div><div style="text-align: center;"><i>Yes, this is my normal seating position. Marvel at the amount of space behind the seat! </i></div><br />Other:<br /><ul><li>I preferred the short metal shift paddles over the extended carbon fibre paddles. Something about the metallic clink when I tap my fingernails on the paddles that's lacking with the carbon paddles…</li><li>Having experienced the 720S Spider roof mechanism, the legacy system in the 600LT Spider feels slow as I put the top down prior to leaving the dealer.</li><li>Sport Series Spider cars: the high shelf provides little rearward visibility regardless of roof position. (but who needs to see what's behind them in a supercar??)</li><li>2018 and later Sport Series cars: Backup camera is in the instrument cluster screen. To me, it's harder to use in conjunction with the rearview mirror than the postage stamp display in the centre screen in the 2016/2017 cars.</li><li>Chicane Effect is Chicane Grey with orange metallic flakes:</li></ul><div class="separator" style="clear: both; text-align: center;"><a href="https://1.bp.blogspot.com/-b1lKiwbgAhU/XhPqCu66RyI/AAAAAAAAF2E/T4WD2BFofb0UaYgV6ON9jVl7_CW8AwxvwCEwYBhgL/s1600/2019-04-26%2B12.34.09.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1600" data-original-width="1200" height="320" src="https://1.bp.blogspot.com/-b1lKiwbgAhU/XhPqCu66RyI/AAAAAAAAF2E/T4WD2BFofb0UaYgV6ON9jVl7_CW8AwxvwCEwYBhgL/s320/2019-04-26%2B12.34.09.jpg" width="240" /></a></div><br /><br />I really want to do a proper test drive in the back roads with little traffic, and in a car with the Senna seats. This will almost certainly need to happen on a Saturday morning shortly after the showroom opens at 9a!<br /><br />How I would spec this car: pretty barebones. The only "must-haves" I think are the Senna seats, as well as small practical items such as the soft-close doors, front lift, and battery charger. Skip the visual carbon exterior (the standard palladium pieces are actually painted carbon fibre pieces), skip the carbon interior, skip the leather, skip the audio…<br /><ul><li>Colour of my choice. These days, I'm feeling MSO Amethyst Black, ever since having seen a Senna in this colour during Car Week last year.</li><li>Standard 10 spoke wheels.</li><li>Soft close doors.</li><li>Standard Alcantara interior. Maybe splurge for the orange "By McLaren" Alcantara interior if I'm feeling lucky…</li><li>Senna seats, regular fit.</li><li>Front lift.</li><li>Battery charger.</li></ul><br />Before driving this car, I used to think that the 600LT coupe is the car to get because of the possibility of the roof scoop (for the uninitiated, it makes for an unique soundtrack). However, that's available in any LT coupe, and the uniqueness of the top-firing exhaust in the 600LT cars is most accentuated by a convertible, which was confirmed by this short drive. Therefore the 600LT Spider is now my pick of the two.<br /><br />[1] Neoprufrok, Roof scoop noises. <a href="https://www.youtube.com/watch?v=rte0WJjJIgU">https://www.youtube.com/watch?v=rte0WJjJIgU</a><br />[2] Vehicle Virgins, 600LT delivery. <a href="https://youtu.be/-XqaoHCWuK0?t=936">https://youtu.be/-XqaoHCWuK0?t=936</a><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/bcWnzEBUCHg" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/01/mclaren-600lt-spider-first-impressions.htmltag:blogger.com,1999:blog-712634145575243505.post-42351015005160361442020-01-05T23:15:00.005-05:002020-01-05T23:15:55.362-05:00Codeforces Round #612 (Div. 2) PostmortemLink to contest <a href="https://codeforces.com/contest/1287">here</a><br /><br />What went well<br /><ul><li>I know how DP works?!</li></ul>What went wrong<br /><ul><li>I failed to read B correctly the first time. The problem is about Set (the game), which I have only played once, over 10 years ago. I thought that all features had to be same or different, instead of each feature being independent of each other.</li><li>I took an hour to debug C because I wasn't confident in my dp transition function. Amusingly, my initial state was wrong, which luckily triggered an assert I left in my code, quickly highlighting an issue. </li></ul>Where I got lucky<br /><ul><li> Somehow placed in the top 5% with just ABC???!</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/LqwhrDV2cVU" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2020/01/codeforces-round-612-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-44570287133052688492019-12-29T23:14:00.000-05:002020-01-05T23:14:39.202-05:00Good Bye 2019 PostmortemLink to contest <a href="https://codeforces.com/contest/1270">here</a><br /><br />What went well<br /><ul><li>I managed to prove that my solution to B is optimal.</li></ul>What went wrong<br /><ul><li>Proving that my B solution is optimal took close to an hour.</li><li>I wasn't sure what to do with C. After expressing the sum as S and the xor as X, I first fell into a trap thinking that I can do it with one number, i.e. S + a = 2*(X ^ a). Nothing really came to mind. Then I thought about using two numbers, i.e. S + a + b = 2*(X ^ a ^ b), where I use a to get rid of S, i.e. make the bits of S be all 0s or all 1s. This led me to think about the lowest power of 2 greater than S, but nothing came to mind. I also never thought about using a to get rid of X, i.e. maybe set a = X, which then leads to a really nice solution S + X + b = 2*b, i.e. b = S + X.</li></ul> Where I got lucky<br /><ul><li>A is a 3 minute problem! </li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/IVsTnJiyNa4" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/good-bye-2019-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-57528517786977690622019-12-28T10:16:00.000-05:002020-01-05T22:53:32.226-05:00COLDforces Round #611 (Div. 3) PostmortemLink to contest here<br /><br />What went well<br /><ul><li>The contest was at 9am local time, so I had a good 2.5 hours to wake up.</li></ul>What went wrong<br /><ul><li>I was ill with a cold (laryngitis?!)</li><li>My solution to E died to a silent index out of bounds!!! Time to switch to vector<T>::at() instead of vector<T>::operator[]?!</li><li>I did not think of a working solution for C during the contest, but did so after the contest (and doing the obvious greedy solution worked and was easy to prove correct…) The junk that I submitted managed to pass system tests, but eventually got exposed by the serial hacker, who hacked over 20 C submissions!</li></ul>Where I got lucky<br /><ul><li>I got my first 1 minute submission!! </li><li>C was such a massacre that I managed to gain elo despite solving only 3 problems! Back to blue again!</li></ul><ul></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/ghUozZkimIo" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/coldforces-round-611-div-3.htmltag:blogger.com,1999:blog-712634145575243505.post-47543544435193663232019-12-27T10:13:00.000-05:002020-01-05T22:49:14.906-05:00Educational COLDforces Round 79 PostmortemLink to contest <a href="https://codeforces.com/contest/1279">here</a><br /><br />What went well<br /><ul><li>Nothing really…</li></ul>What went wrong<br /><ul><li>I was still ill with a cold (laryngitis?!)</li><li>I took a few passes to understand B; I misread the problem the first couple times. Eventually I got the problem after nearly an hour.</li><li>I didn't realize that I misread C until after the contest. I thought one can remove multiple presents in between popping and pushing back the unused presents.</li></ul>Where I got lucky<br /><ul><li>A was back to a straightforward 3-minute problem.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/bIr3AW3RgMc" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/educational-coldforces-round-79.htmltag:blogger.com,1999:blog-712634145575243505.post-11622468758645981242019-12-24T20:06:00.000-05:002020-01-05T22:44:12.862-05:00COLDforces Round #610 (Div. 2) PostmortemLink to contest <a href="https://codeforces.com/contest/1282">here</a>.<br /><br />What went well<br /><ul><li> I was able to figure out a clean solution for B2.</li></ul>What went poorly<br /><ul><li>I was ill with a cold (laryngitis?!)</li><li>I wasn't sure how to do C because I wasn't able to prove optimality of a solution. </li></ul>Where I got lucky<br /><ul><li>Not today</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/xtxRd31rs0U" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/coldforces-round-610-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-85084051122826131542019-12-19T23:20:00.001-05:002019-12-19T23:20:08.031-05:00Educational Codeforces Round 78 (Div. 2) PostmortemLink to <a href="https://codeforces.com/contest/1278">contest</a>.<br /><br />What went well<br /><ul><li>I got A in 3 minutes.</li></ul>What went poorly<br /><ul><li>I wasn't sure how to prove B during the contest. Then I decided to binary search when a linear search would have run in time. However, I had a bug in my binary search because I needed to look at particular residues mod 4, which required extra debugging to get right. All this took…1.5 hours.</li><li>I was completely wrong for C because I didn't realize that not all larger subarrays may work.</li></ul>Where I got lucky<br /><ul><li>Apparently I probably won't lose too much elo.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/LrfzCQXGk1k" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/educational-codeforces-round-78-div-2.htmltag:blogger.com,1999:blog-712634145575243505.post-16514149925055100082019-12-17T22:21:00.003-05:002019-12-17T22:21:34.022-05:00Codeforces Global Round 6 PostmortemLink to <a href="https://codeforces.com/contest/1266">contest</a>.<br /><br />What went well<br /><ul><li>I solved A, B, C.</li></ul>What went poorly<br /><ul><li>I don't know the properties of natural numbers divisible by 60. My solution is so disgusting that I would happily nominate my solution for this year's Wall of Shame. </li><li>I misread B and thought that the tower of dice was visible from just the front, instead of both front and back. </li></ul>Where I got lucky<br /><ul><li>I didn't lose much elo for a mediocre showing. </li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/QI2tb3pQdrI" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/codeforces-global-round-6-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-29240526133839788652019-12-15T11:39:00.002-05:002019-12-15T13:24:20.512-05:00Codeforces Round #607 (Div. 2) PostmortemLink to <a href="https://codeforces.com/contest/1281">contest</a>.<br /><br />What went well<br /><ul><li>I solved A in 2 minutes.</li></ul>What went wrong<br /><ul><li>I was too hasty on B, leading to two wrong submissions, and took a total of over 20 minutes.</li><li>I took over an hour on C because I wasn't clear at all about my recurrences and starting values. </li></ul>Where I got lucky<br /><ul><li>Everyone else sucks more at math, so a slow C with one penalty got me in the top 400 (top 6%).</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/PWLG6oJl4Fg" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/codeforces-round-607-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-11636014788705532642019-12-05T22:49:00.002-05:002019-12-05T22:50:20.364-05:00Codeforces Round #604 (Div. 2) PostmortemLink to <a href="https://codeforces.com/contest/1265">contest</a>.<br /><br />What a dumpster fire of a contest.<br /><br />What went well<br /><ul><li>I got B quickly.</li></ul>What went wrong<br /><ul><li>I didn't know how to solve A, so came up with a horribly convoluted solution with lots of cases. This and weak testing resulted in an incorrect submission, but I realized my mistake after the Wrong Answer verdict and patched my solution.</li><li>C was evil because it had ample opportunity for off-by-one errors, one of which killed my solution.</li><li>My attempt at implementing D yielded a giant pile of spaghetti, which was unsurprisingly wrong.</li><li>E is definitely doable in 20min start to finish, but my combinatorics skills isn't strong enough for me to write down the recurrence after reading the problem.</li></ul>Where I got lucky<br /><ul><li>What luck?! </li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/vl62Xv1o4k4" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/12/codeforces-round-604-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-22517145496052662392019-11-30T10:19:00.001-05:002019-12-01T09:54:25.018-05:00Codeforces Round #603 (Div. 2) PostmortemLink to <a href="https://codeforces.com/contest/1263">contest</a>.<br /><br />What went well<br /><ul><li>I got ABCD.</li><li>Expanding on getting ABCD, I got C and D fairly quickly, at T+36min and T+48min respectively. (Then again, D was not particularly hard, as evidenced by its 1500 rating). </li></ul>What went wrong<br /><ul><li>I didn't get A until T+1h30 and two wrong tries.</li><li>I did not upload anything for E because my fastest solution sketches were O(NlogN), which I thought were too slow for N = 1,000,000. Turns out that O(NlogN) and a good constant factor is fine for such large N.</li><li>I also misread E: I thought that the cursor can be moved to the left of the starting position, but the problem clearly says that it can't. </li></ul>Where I got lucky<br /><ul><li>Implementing C and D went very smoothly, taking 12min from end (open problem statement) to end (pretests passed).</li><li>E felt approachable.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/VQaC4gEF3_A" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/11/codeforces-round-603-div-2-postmortem.htmltag:blogger.com,1999:blog-712634145575243505.post-24934817967046342512019-11-28T13:17:00.002-05:002019-11-28T13:19:19.953-05:00Educational Codeforces Round 77 (Div. 2) PostmortemLink to <a href="https://codeforces.com/contest/1260">contest</a>.<br /><br />What went well<br /><ul><li>I didn't give up.</li><li>I quickly figured out the approach for D, which was binary searching for the answer.</li></ul>What went wrong<br /><ul><li>I got A four (!!!) minutes before the contest ended (at T + 01h56).</li><li>I didn't get D.</li><li>I incurred a lot of penalty from wrong-answering B (twice) and C (once).</li><li>I had no milk for my pre-contest coffee.</li><li>I felt pretty awful waking up at 0530 to do the contest.</li></ul>Where I got lucky<br /><ul><li> The contest was hard for everyone else, so I only lost less than 50 elo for my poor performance.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/bG5wi_EMAHc" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/11/educational-codeforces-round-77-div-2.htmltag:blogger.com,1999:blog-712634145575243505.post-3019087044386376272019-11-23T15:24:00.001-05:002019-11-23T15:26:14.703-05:00A Taste of Quantitative TradingThink you're interested in quantitative trading? Try your hand at this problem, courtesy of E6 Trading:<br /><blockquote class="tr_bq">Two card players have hand strengths distributed independently & uniformly over [0, 1] and are playing for an existing pot of $100. Player 1 can check or bet $100. If Player 1 checks, the player with the stronger hand wins the pot. If Player 1 bets, Player 2 can call the bet or fold. Given both players are risk-neutral <strike>paperclip</strike> expectation maximizers, how does each play?</blockquote><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/ZcREugEFD10" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/11/a-taste-of-quantitative-trading.htmltag:blogger.com,1999:blog-712634145575243505.post-20924745764864965112019-11-20T20:58:00.002-05:002019-11-20T20:58:45.682-05:00Codeforces Round #597 (Div. 2) PostmortemLink to <a href="https://codeforces.com/contest/1245">contest</a>. <br /><br />What went well<br /><ul><li>I solved C and D relatively quickly. </li><li>I was pretty close on E1.</li></ul>What went wrong<br /><ul><li>I didn't get B.</li><li>B had more than 2 errata.</li><li>I didn't read E2 before I started to think about E1. This time, E2 was simply the same problem, but with higher limits. </li></ul>Where I got lucky<br /><ul><li>Fewer people than usual solved D, so I managed to get rank #401 (top 4%) with just ACD. Normally ranking that high needs a reasonably fast ABCD.</li></ul><img src="http://feeds.feedburner.com/~r/DoesntExist/~4/C4iwA4-2Luc" height="1" width="1" alt=""/>cherry suhttp://www.blogger.com/profile/16615103822232949422noreply@blogger.com0http://blog.shewu.me/2019/11/codeforces-round-597-div-2-postmortem.html