Toggle navigation
Discord
YouTube
Facebook
Instagram
english
english
українська
Algotester 4.7
Build 712
2025-09-07
Log In
Contact Us
College
Sponsors
Donate
Sources
C++ 14 (GCC 6.4)
#include <bits/stdc++.h> using namespace std; int main() { long long a, b; cin >> a >> b; if (abs(b - a) % 12 != 0) cout << -1 << '\n'; else cout << (a + b) * 13 / 2 << '\n'; return 0; }