Codeforces Solution 1178C. Tiles

Solve in C++:

#include <iostream>
using namespace std;
int main()
{
    int w,h,i,result=1;
    cin>>w>>h;
    for(i=0;i<w+h;i++)
    {
        result=(result+result)%998244353;
    }
    cout<<result<<endl;
    return 0;
}



No comments

Most View Post

Recent post

Codeforces Round 925 (Div. 3) 1931D. Divisible Pairs Solution

    Problem Link  :   https://codeforces.com/contest/1931/problem/D S olution in C++: /// Author : AH_Tonmoy #include < bits / stdc ++. ...

Powered by Blogger.