AtCoder abc280 E
// compile: g++ -o data data.cpp -O3 -std=gnu++20 -Wall -Wextra -Wshadow -D_GLIBCXX_ASSERTIONS -ggdb3 -fmax-errors=2 -DLOCAL
// run: ./data < data.in
#include <bits/stdc++.h>
using namespace std;
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt")
#ifdef LOCAL
#include <debug/codeforces.h>
#define debug(x...) {_variables(#x);_print(x);}
#else
#define debug(x...)
#endif
template<typename...Args> void print_(Args...args){((cout<<args<<" "),...)<<endl;}
#define rep(i,a,b) for(int i=(a);i<(int)(b);++i)
#define sz(v) ((int)(v).size())
#define print(...) print_(__VA_ARGS__);
#define INTMAX (int)(9223372036854775807)
#define INTINF (int)(1152921504606846976)
// #define int long long
#define MAXN 200010
#include <atcoder/modint>
using namespace atcoder;

int n, p;
using mint = modint998244353;
mint dp[MAXN];

int32_t main() {
    ios::sync_with_stdio(false); cin.tie(nullptr); cout.tie(nullptr);

    cin >> n >> p;
    dp[1] = mint(1);
    rep(i, 2, n+1) {
        dp[i] = ((dp[i-1] * (100-p) + dp[i-2] * (p)) / 100) + 1;
    }
    cout << dp[n].val() << endl;

    return 0;
}

Comments

  1. 11 months ago
    2025-12-06 2:25:15

    Been playing s9game for a couple of days now and it’s really grown on me. It’s engaging. Check it out here s9game

  2. 11 months ago
    2025-12-19 13:40:12

    If you’re a fan of gà đòn c1, this site is for you. The best place on the internet for this kind of content. Check it out now at gà đòn c1.

  3. 10 months ago
    2025-12-29 6:08:27

    Anyone using ketqua04 for their results? I’m curious if it’s accurate compared to others. Let me know what you think! Here’s the link: ketqua04

  4. 3 months ago
    2026-8-14 1:06:36

    Alright, 777sxgamedownload.net looks promising! Gotta check if they actually have the good stuff. Fingers crossed for those rare game downloads! 777sxgamedownload

  5. 3 months ago
    2026-8-14 1:06:53

    Yo, check out j19lm. Not too shabby. Its easy to get around, and its been nice so far. If that’s your sort of thing, check them out: j19lm

  6. 3 months ago
    2026-8-14 1:07:13

    boocasinologin was super easy to use. Nice, simple interface and I had no trouble getting in and playing. Not bad! Take a look boocasinologin.

  7. 3 months ago
    2026-8-14 2:25:06

    Living in the islands makes me appreciate sites that run perfectly even on slower connections. This one handles everything smoothly and the local payment options make deposits a breeze. It feels like a neighborhood hangout where everyone looks out for each other. I spend my afternoons here and the vibes are always top tier. Highly suggest you drop by. phylaro

  8. 3 months ago
    2026-8-14 2:25:22

    I stumbled upon this gem a few months ago and it has completely exceeded my expectations. The whole atmosphere is so relaxed and the team really listens to what the community wants to improve. I always leave with a great impression and I cannot wait for my next visit. 88fabet

  9. 3 months ago
    2026-8-14 2:25:42

    What stands out the most is how welcoming the whole platform feels for new players. I never had to wait long when cashing out and the support team answered every question patiently. The game library rotates nicely so I never get bored with the same titles. Join the fun at myminion888

  10. 2 months ago
    2026-8-26 17:50:45

    Really impressed with the customer service here. They helped me resolve my deposit issue in minutes. ph99jl is definitely one of the most trustworthy platforms I have tried.

  11. 1 month ago
    2026-9-24 8:20:55

    [4763]crickex aff লগইন এবং বিকাশ দিয়ে অনলাইন ক্যাসিনো গেম,crickex aff লগইন করে সেরা স্লট গেম সাইট এবং লাইভ ক্যাসিনো খেলার নিয়ম জানুন। দ্রুত crickex aff app download করে গেম খেলা শুরু করুন। visit: crickex aff

  12. 4 weeks ago
    2026-10-03 13:09:03

    Great community and a very friendly vibe. It feels more like a club than just a website. You should check out idbakso108

  13. 4 weeks ago
    2026-10-05 14:06:22

    Finally found a platform that doesn’t lag during peak hours. The game variety is impressive and the customer support is actually helpful. pk68vippk is definitely my new go-to.

  14. 1 week ago
    2026-10-24 4:12:22

    Finally found a place where the bonuses actually make sense. The registration process was a breeze and I was playing in minutes. vn888now

Send Comment Edit Comment


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗㆆ)
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
颜文字
Emoji
小恐龙
花!
Previous
Next