Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- const int SIZE2 = 5;
- const int SIZE3 = 5;
- void main()
- {
- cout << "answer question No.5\n\n";
- int arr[SIZE2], arr2[SIZE3], i = 0, counter = 0;
- cout << "please enter " << SIZE2 << " numbers: ";
- for (i = 0; i < SIZE2; i++)
- cin >> arr[i];
- cout << "please enter " << SIZE3 << " numbers: ";
- for (int j = 0; j < SIZE3; j++)
- {
- cin >> arr2[j];
- i = 0;
- if (arr[i] == arr2[j])
- {
- cout << counter;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment