Advertisement
Guest User

main.pp

a guest
Jan 17th, 2019
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.37 KB | None | 0 0
  1. #include <iostream>
  2. #include "List.h"
  3. #include "Node.h"
  4.  
  5. using namespace std;
  6.  
  7. int main() {
  8.  
  9.     List<int> lista;
  10.  
  11.     int M = 0;
  12.     cin >> M;
  13.  
  14.     int x = 0;
  15.  
  16.     for (int i = 0; i < M; i++) {
  17.         cin >> x;
  18.         lista.add(x);
  19.     }
  20.  
  21.     int N = 0;
  22.     cin >> N;
  23.    
  24.     int y = 0;
  25.  
  26.     for (int i = 0; i < N; i++) {
  27.         cin >> y;
  28.         lista.remove(y);
  29.     }
  30.  
  31.  
  32.     lista.print();
  33.  
  34.     return 0;
  35.  
  36. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement