코드를 작성할 때 가장 먼저 해야되는 것 : 시행공간 시행공간 >> Point가 필요하다 int count = 0; for (int i = 2; i < 10000001; i++) { // 시행공간 if (A[i] != 0) { long temp = A[i]; while ((double)A[i] = (double)Min / (double)temp) { count++; } temp = temp*A[i]; } } } for 로 표현되는 시행공간 혹은 function Hard deck/Deep dive 2022.08.02
for 내부의 if로 공간 나누기 for (int i = 0; i 1) { plusPq.add(data); } else if (data == 1) { one++; } else if (data == 0) { zero++; } else { minusPq.add(data); } } 공간을 나눠서 저장한다 Hard deck/Basic 2022.08.02
for Projecting int count = 0; for (int i = 2; i < 10000001; i++) { if (A[i] != 0) { long temp = A[i]; // Projecting while ((double)A[i] = (double)Min / (double)temp) { count++; } temp = temp*A[i]; } } } long temp는 for 공간에 projected된다 Hard deck/Basic 2022.08.02
001 : Point가 발견되는 공간 인식하기 import java.util.Scanner; public class Main { public static void main (String[] args) { // Input Supply Scanner Scanner sc = new Scanner(System.in); int M = sc.nextInt(); int N = sc.nextInt(); // Preprocessing int[] A = new int[N+1]; for (int i = 2; i 코테 기초 2022.08.02
Fast Recovery // Operating DFS static void DFS(int v) { if (visited[v]) { /// >>> return; } visited[v] = true; for (int i : A[v]) { if (visited[i] == false) { DFS(i); } } } 내가 작업을 진행하지 않아도, 이미 완성조건에 부합하는 것이 무엇인지 확인하고 작업 전에 빠르게 회수함 Hard deck/Deep dive 2022.08.02