void main(){ for (i=0;i<20;i++){ & cout<<"enter a number: "; & cin>>arr[i]; } cout<<"\nHere are all entered numbers:\n"; for (i=0;i<20;i++){ & cout<<arr[i]<<" "; } cout<<"\n\nHere are entered even numbers:\n"; for (i=0;i<20;i++){ & if (even(arr[i])) cout<<arr[i]<<" "; } cout<<"\n\n"; }
Comments
Leave a comment