Advertisement
edytedy

Untitled

Oct 17th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.21 KB | None | 0 0
  1. float a, i, s=0;
  2. for(i=1; i<=4; i++)
  3. {
  4. cout<<"Introduceti numarul: "; cin>>a;
  5. if(a>0)
  6. s=s+a;
  7. else
  8. s=s;
  9. }
  10. cout<<"Suma maxima este: "<<s;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement