We will hold Tokio Marine & Nichido Fire Insurance Programming Contest 2025 (AtCoder Beginner Contest 402).
- Contest URL: https://atcoder.jp/contests/abc402
- Start Time: http://www.timeanddate.com/worldclock/fixedtime.html?iso=20250419T2100&p1=248
- Duration: 100 minutes
- Writer: MtSaka, sounansya
- Tester: Nyaan, yuto1115
- Rated range: ~ 1999
- The point values: 100-200-300-400-450-525-650
We are looking forward to your participation!









Impossible to log in into AtCoder, Cloudflare blocks. Uncaught TurnstileError: [Cloudflare Turnstile] Error: 300010. at g (api.js:1:11022) at N (api.js:1:36515) Formerly Refused to execute script from 'https://pp.d2-apps.net/v1/impressions/log?client_id=468&site_url=https%3A%2F%2Fatcoder.jp%2Flogin%3Fcontinue%3Dhttps%253A%252F%252Fatcoder.jp%252F&referer=https%3A%2F%2Fatcoder.jp%2Flogin%3Fcontinue%3Dhttps%253A%252F%252Fatcoder.jp%252F&__version=1.0.0&__ord=2140118752267&callback=__pfunc&viewport=1920x945&language=en-US&first_party_uid=WRJEn4pqIfj9yqrrFDFvSXGNgGO3MW7j&local_storage_uid=hX3FbroDtZwaE62uYdn15cdPts4ZSyz5&c_1=atcodercontest&c_2=ClientSite' because its MIME type ('image/gif') is not executable. At advice by ChatGPT, blocked pp.d2-apps.net in the hosts file. It worked for one hour, and than the problems came back
wtf is this
Hope to solve ABCDEF.
Seems that AtCoder is experiencing tough condition every time when the competition's sponsor is Tokio Marine & Nichido Fire Insurance. Hope that this round will be Rated.
I think there's a typo. "sponser" should be "sponsor"
when 20:30(UTF+8):
Funny. It seems that ABC has become a "copy paste modify chatgpt code" contest.
Which extension are u using?
ac-predictor
Tks!
AI Beat Contest
Another speedcoder. Only 5 passed G but ~1000 passed F.
$$$O(T\sqrt n)$$$ solution is able to pass G. I think the constraints should have been made to $$$10^9$$$ or so.
But then the answer will be more than 2^63.
what is problem with my implementation for E, my approach is similar to the editorialYour DP table is undersized. you declared it as vector<vector>(1<<8, vector(5000, -1.0)) but since x can be up to 5000 you end up indexing dp[...][5000] on a vector that only goes 0–4999, Just size the second dimension to X+1 so it covers 0 through X inclusive.
Second, you never guard against overspending: you compute
double cand = p*(s + solve(nxt, x-c)) + (1-p)*solve(his, x-c);
even when c > x. Both calls then see a negative budgete and return 0 giving you an illegal “free” gain of p * s To fix it : before recursing skip any problem you can’t afford:
if (c > x) continue;
Thank you.
No worries
what is wrong with this code for problem C — https://atcoder.jp/contests/abc402/submissions/65031146 ??
Delete the 31st line.
but why ? if x is not present as ingredient then I should ignore right ?
haven't output yet
And it doesn't matter. Because if x is not present as ingredient then the 32nd line won't be executed.
Why This code for F should use long long.
In problem d. If we have an odd number of points, wouldn't every line intersect? I believe there will not be any parallel line.
Consider 5 points in circle. Line (2, 5) and (3, 4) are parallel.