We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7ef4ae8 commit 27a6d60Copy full SHA for 27a6d60
Codeforces_Contests/9_Round_667_Div_3/A.cpp
@@ -0,0 +1,32 @@
1
+#include <string>
2
+#include <vector>
3
+
4
+#include <algorithm>
5
+#include <cmath>
6
7
+using namespace std;
8
9
+int main()
10
11
+{
12
+ int noOfTestCase{};
13
+ cin>>noOfTestCase;
14
+ long long a[noOfTestCase];
15
+ long long b[noOfTestCase];
16
+ for(int i=0;i<noOfTestCase;i++){
17
+ cin>>a[i];
18
+ cin>>b[i];
19
+ }
20
21
22
+ if(abs(a[i]-b[i])==0){
23
+ cout<<"0"<<endl;
24
+ }else if(abs(a[i]-b[i])%10==0){
25
+ cout<<(abs(a[i]-b[i])/10)<<endl;
26
+ }else{
27
+ cout<<(abs(a[i]-b[i])/10)+1<<endl;
28
29
30
31
+ return 0;
32
+}
0 commit comments