목록백준 (8)
hyeals study
import java.util.Scanner; public class Main { static int N; static int M; static boolean[] visited; static int[] answer; static StringBuilder ans = new StringBuilder(); static void backtracking(int num){ if(num==M){ for(int i=0; i
import java.util.Scanner; public class Main { static int N; static int M; static int[] answer; static StringBuilder ans = new StringBuilder(); static void backtracking(int num){ if(num==M){ for(int i=0; i
import java.util.Scanner; public class Main { static int N; static int M; static boolean[] visited; static int[] answer; static StringBuilder ans = new StringBuilder(); static void backtracking(int num){ if(num==M){ for(int i=0; i
import java.util.Scanner; public class Main { static int N; static int M; static boolean[] visited; static int[] answer; static StringBuilder ans = new StringBuilder(); static void backtracking(int num){ if(num==M){ for(int i=0; i
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(); int answer = 0; int count = 0; while(count!=N){ answer ++; if(String.valueOf(answer).contains("666")){ count ++; } } System.out.println(answer); } }
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(); int sum = 0; int answer = 0; for(int i=0; i
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(); int M = sc.nextInt(); int[] card = new int[N]; int max = 0; int sum = 0; for(int i =0; i
import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; import java.util.Comparator; public class Main { public static void main(String[] args) { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = 0; try{ N = Integer.parseInt(br.readLine()); }catch (Exception e){ e.printStackTrace(); } String[][] arr = new String[N][2]; String[] re..