fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int m,n,sum=0,i;
  5. scanf("%d %d",&m,&n);
  6. if(m>n){
  7. m=n+m;
  8. n=m-n;
  9. m=m-n;
  10. }
  11. for(i=m;i<=n;i++){
  12. if(i%17==0)
  13. sum+=i;
  14. }
  15. printf("%d",sum);
  16. return 0;
  17. }
  18.  
Success #stdin #stdout 0s 5276KB
stdin
50 85
stdout
204