Saleh127

CF 1409A

Sep 4th, 2020
154
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3. #define ll long long
  4. #define test int t; cin>>t; while(t--)
  5. int main()
  6. {
  7. ios_base::sync_with_stdio(0);
  8. cin.tie(0);cout.tie(0);
  9.  
  10. test
  11. {
  12.  
  13. ll a,c,d,e,f,i,j,k,l;
  14. cin>>a>>c;
  15. d=abs(a-c);
  16. if(d%10==0) cout<<d/10<<endl;
  17. else cout<<1+d/10<<endl;
  18.  
  19.  
  20. }
  21.  
  22.  
  23. return 0;
  24. }
  25.  
Advertisement
Add Comment
Please, Sign In to add comment