Advertisement
Saleh127

UVA 138

Aug 29th, 2020
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 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. ll a,c=0,e=8;
  11. double d;
  12. while(c<10)
  13. {
  14. d=sqrt((e*e+e)/2);
  15. a=d;
  16. if(d==a)
  17. {
  18. printf("%10lld%10lld\n",a,e);
  19. c++;
  20. }
  21. e++;
  22. }
  23.  
  24.  
  25. return 0;
  26. }
  27.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement