djelad1

Untitled

Nov 14th, 2014
146
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3. const int SIZE2 = 5;
  4. const int SIZE3 = 5;
  5.  
  6.  
  7. void main()
  8. {
  9.  
  10. cout << "answer question No.5\n\n";
  11.  
  12. int arr[SIZE2], arr2[SIZE3], i = 0;
  13. cout << "please enter " << SIZE2 << " numbers: ";
  14. for (i = 0; i < SIZE2; i++)
  15.  
  16. cin >> arr[i];
  17.  
  18. cout << "please enter " << SIZE3 << " numbers: ";
  19. for (int j = 0; j < SIZE3; j++)
  20. {
  21. cin >> arr2[j];
  22.  
  23. if (arr[i] == arr2[j])
  24. {
  25.  
  26. }
  27. cout << arr2[j] << endl;
  28. }
  29.  
  30. system ("pause");
  31. }
Advertisement
Add Comment
Please, Sign In to add comment