Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <cstdlib>
- using namespace std;
- bool sprawdz(float T[],int n)
- {
- for(int i=0;i<n;i++)
- {
- if(T[i]>=9)return false;
- }
- return true;
- }
- int main()
- {
- float T[9];
- for(int i=0;i<9;i++)
- {
- T[i] = rand()%32-4;
- cout<<T[i]<<endl;
- }
- if(sprawdz(T,9)==true)cout<<"Mniejsze od 9";
- else cout<<"Wieksze od 9";
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement