Skip to content

Instantly share code, notes, and snippets.

@modos
Created April 24, 2023 07:07
Show Gist options
  • Save modos/7a05b75a076133c7ad4d76d9941cad52 to your computer and use it in GitHub Desktop.
Save modos/7a05b75a076133c7ad4d76d9941cad52 to your computer and use it in GitHub Desktop.
سی‌شارپ نوردی
#include <iostream>
#include <cmath>
using namespace std;
int main() {
int a, b, ans = 0;
cin >> a >> b;
if (a % 2 != b % 2) {
ans++;
}
if (ceil(a/2.0) != ceil(b/2.0)) {
ans++;
}
cout << ans;
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment