백준 4889 java
-
boj)4889 - 안정적인 문자열PS/boj 2020. 10. 14. 15:48
import java.io.*; import java.util.Stack; public class boj_4889 { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(System.out)); String str; int cnt = 0; while ( !(str = br.readLine()).contains("-") ) { cnt++; Stack stack = new Stack(); for (int i = 0..