Advertisement
SergioRP

Untitled

Feb 21st, 2019
161
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. #include <iostream>
  2. #include<map>
  3. #include<string>
  4.  
  5. using namespace std;
  6.  
  7. int main() {
  8. int n, i, j, x;
  9. cin >> n;
  10. string enq = "ENQUEUE", deq = "DEQUEUE", stop = "STOP", command;
  11.  
  12. // enquanto nao der o comando de acabar
  13. while (n != 0) {
  14. map<int, int> team;
  15.  
  16. // para cada time
  17. for (i = 0; i < n; i++) {
  18. // pega o valor do jogador;
  19. cout << "inserindo time " << i + 1 << ": ";
  20. cin >> x;
  21.  
  22. // armazena-o no time
  23. team[x] = i;
  24. }
  25.  
  26. cin >> command;
  27. if(!command.compare(enq)) {
  28. cout << "ALO CARAI" << endl;
  29. }
  30.  
  31.  
  32. cin >> n;
  33. }
  34.  
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement