<awangdev>Backspace String Compare_1.java
private String type(String s) {

        Stack<Character> stack = new Stack<>();
        for (char c : s.toCharArray()) {
            if (c == '#') {
                if (!stack.isEmpty()) stack.pop();
            } else {
                stack.push(c);
            }
        }
        StringBuffer sb = new StringBuffer();
        while (!stack.isEmpty()) {
            sb.append(stack.pop());
        }
        return sb.toString();
    }
private String var_0 ( String var_2 ) {
  Stack < Character > var_5 = new Stack < > ( ) ;
  for ( char var_7 : var_2 . toCharArray ( ) ) {
    if ( var_7 == '#' ) {
      if ( ! var_5 . isEmpty ( ) ) var_5 . pop ( ) ;
    }
    else {
      var_5 . push ( var_7 ) ;
    }
  }
  StringBuffer var_13 = new StringBuffer ( ) ;
  while ( ! var_5 . isEmpty ( ) ) {
    var_13 . append ( var_5 . pop ( ) ) ;
  }
  return var_13 . toString ( ) ;
}
