Advertisement
Guest User

Untitled

a guest
Nov 20th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. else if ( type_operation == "leave") {
  2.  
  3. int s;
  4.  
  5. in >> s;
  6.  
  7. int le = l[s];
  8.  
  9. int ri = r[s];
  10.  
  11. if( l[s] != 0 || r[s] != 0 ){
  12.  
  13. l[s] = 0;
  14.  
  15. r[s] = 0;
  16.  
  17. r[le] = ri;
  18.  
  19. l[ri] = le;
  20.  
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement