TOPIC
Presentation error
mrncandido asked 5 years ago
#include <iostream>
#include <iomanip>
using namespace std;
int main() {
long long N, M, p, s;
cin >> N;
long long fila[N];
for(int i=1; i<=N; i++){
fila[i]=0;
}
for(int i=1; i<=N; i++){
cin >> p;
fila[i]=p;
}
cin >> M;
for(int i=1; i<=M; i++){
cin >> s;
for(int i=1; i<=N; i++){
if(fila[i]==s){
fila[i]=0;
}
}
}
for(int i=1; i<=N; i++){
if(fila[i]!=0){
if(i<N){
cout << fila[i] << " ";
} else {
cout << fila[i];
}
}
}
cout << endl;
}