Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Xadrez - Fase 1 P1 - 2018
- //Por Lucio Cardoso
- //Complexidade: O(1)
- #include <bits/stdc++.h>
- using namespace std;
- int main(void)
- {
- int l, c;
- cin >> l >> c;
- if ((l%2) == (c%2)) {
- // se l e c tem mesma paridade
- cout << "1\n";
- }
- else {
- // se l e c tem paridades distintas
- cout << "0\n";
- }
- }
Add Comment
Please, Sign In to add comment