Advertisement
Josif_tepe

Untitled

May 20th, 2024
568
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.25 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main()
  5. {
  6.     int i;
  7.     int zbir = 0;
  8.     for(i = 20; i >= 5; i -= 1)
  9.     {
  10.         if(i % 2 == 0)
  11.         {
  12.             zbir += i;
  13.         }
  14.     }
  15.     cout << zbir << endl;
  16.     return 0;
  17. }
  18.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement