PS
-
11655 ROT13PS/백준 2022. 3. 19. 22:53
import java.io.*; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(System.out)); String inputVal = buf.readLine(); for (int i = 0; i = 'a' && inputVal.charAt(i) = 'A' && inputVal..
-
2743 단어 길이 재기PS/백준 2022. 3. 19. 22:27
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); String s = buf.readLine(); System.out.println(s.length()); } }
-
10820 문자열 분석PS/백준 2022. 3. 18. 00:03
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); String s = ""; /*** * a ~ z : 97 ~ 122 * A ~ Z : 65 ~ 90 * 0 ~ 9 : 48 ~ 57 * '' : 32 */ while ((s = buf.readLine()) != null) { int[] res = new int[4];..
-
10809 알파벳 찾기PS/백준 2022. 3. 16. 22:17
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); String inputVal = buf.readLine(); int[] cntArray = new int[26]; for (int i = 0; i < cntArray.length; i++) { cntArray[i] = -1; } for (int i = 0; i < in..
-
10808 알파벳 개수PS/백준 2022. 3. 15. 23:53
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); String inputVal = buf.readLine(); int[] cntArray = new int[26]; for (int i = 0; i < inputVal.length(); i++) { cntArray[inputVal.charAt(i)-97]++; } for..
-
10992 별 찍기 17PS/백준 2022. 3. 14. 22:00
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); int n = Integer.parseInt(buf.readLine()); for (int i = 1; i < n; i++) { System.out.printf(" "); } System.out.println("*"); for (int i = 2; i
-
10991 별 찍기 - 16PS/백준 2022. 3. 13. 23:58
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); int n = Integer.parseInt(buf.readLine()); for(int i = 0; i < n; i++) { for(int j = 0; j
-
2446 별 찍기 - 9PS/백준 2022. 3. 13. 00:18
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); int n = Integer.parseInt(buf.readLine()); for(int i=0; i < n; i++) { for(int j=0; j < i; j++) { System.out.print(" "); } for (int k = 0; k < (2 * n - ..
-
2522 별 찍기 - 12PS/백준 2022. 3. 12. 23:54
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); int inputValue = Integer.parseInt(buf.readLine()); for(int i=0,k=inputValue; i
-
2445 별 찍기 - 8PS/백준 2022. 3. 10. 23:09
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); int inputVal = Integer.parseInt(buf.readLine()); int loopLeng = inputVal * 2; int startIdx = 0; int endIdx = 0; for (int i = 1; i