#include<bits/stdc++.h>
using namespace std;
#define st first
#define nd second
#define pb push_back
typedef long long LL;
int main()
{
ios_base::sync_with_stdio(0);
cin.tie(0);
int k;
cin>>k;
for(int i=0;i<k;i++)
{
int n,m;
cin>>n>>m;
cout<<(min(n,m)-1)*2<<"\n";
}
return 0;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
2176 KB |
Output is correct |
2 |
Correct |
0 ms |
2176 KB |
Output is correct |
3 |
Correct |
0 ms |
2176 KB |
Output is correct |
4 |
Correct |
0 ms |
2176 KB |
Output is correct |
5 |
Correct |
0 ms |
2176 KB |
Output is correct |
6 |
Runtime error |
0 ms |
2176 KB |
Execution killed because of forbidden syscall writev (20) |
7 |
Runtime error |
0 ms |
2176 KB |
Execution killed because of forbidden syscall writev (20) |
8 |
Runtime error |
0 ms |
2176 KB |
Execution killed because of forbidden syscall writev (20) |
9 |
Runtime error |
0 ms |
2176 KB |
Execution killed because of forbidden syscall writev (20) |
10 |
Runtime error |
0 ms |
2176 KB |
Execution killed because of forbidden syscall writev (20) |