Advertisement
AquaBlitz11

[t002] fibonacci

Oct 9th, 2018
258
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.14 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5.     long long a, b;
  6.     scanf("%lld%lld", &a, &b);
  7.     printf("%lld\n", (b+a)*(b-a+1)/2);
  8.  
  9.     return 0;
  10. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement