Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- int broj;
- int broj2;
- const int i = 0;
- int sabiranje;
- while (i < broj)
- {
- cout << "Unesite broj: ";
- cin >> broj;
- if (i < broj) {
- broj2 = broj;
- sabiranje += broj2;
- }
- }
- cout << "Suma je: " << sabiranje;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement