Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- typedef long long int ll;
- int main() {
- int n;
- cin >> n;
- for (int i = 0; i < n; i++) {
- int a, b;
- cin >> a >> b;
- cout << (19 * b) + ((a + 239)*(a + 366)) / 2 << endl;
- }
- //system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement