Codeforces #258 (Div. 2) A. Game With Sticks

来源:互联网 发布:打车软件分析报告 编辑:程序博客网 时间:2024/06/06 09:39

很简单的一道题,取行列中较小值对2取模即可

证明就省略了吧

代码如下:

<span style="font-size:18px;">#include <cstdio>#include <iostream>#include <algorithm>#define MAXN 10010#define LL long longusing namespace std;int main(void) {    int a, b;    while(cin >> a >> b) {        a = min(a, b);        if(a % 2) {            cout << "Akshat" << endl;        } else cout << "Malvika" << endl;    }    return 0;}</span>

0 0
原创粉丝点击