전체 글848 프림 알고리즘(Prim Path)-(1) 보호되어 있는 글 입니다. 2021. 7. 14. 백준 10809 import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main10809 { public static void main(String[] args) throws IOException { BufferedReader bf = new BufferedReader(new InputStreamReader(System.in)); String S = bf.readLine(); int[] alpha = new int[26]; for (int i = 0; i < alpha.length; i++) { alpha[i] = -1; } for (int i = 0; i < S.length(); i++.. 2021. 7. 13. 백준 11720 import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main11720 { public static void main(String[] args) throws IOException { BufferedReader bf = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(bf.readLine()); String num = bf.readLine(); int number =0; int sum = 0; for(int i=0; i 2021. 7. 13. 크루스칼 알고리즘(KruskalPath) 보호되어 있는 글 입니다. 2021. 7. 13. 다익스트라 최단 경로(DijkstraPath) 보호되어 있는 글 입니다. 2021. 7. 12. 11 컬렉션 프레임웍(7) Collections Arrays가 배열과 관련된 메서드를 제공하는 것처럼, Collections는 컬렉션과 관련된 메서드를 제공한다. fill(), copy(), sort(), binarySearch() 등의 메서드는 두 클래스에 모두 포함되어 있으며 같은 기능을 한다. java.util.Collection은 인터페이스고, java.util.Collections는 클래스이다. 컬렉션의 동기화 멀티 쓰레드(multi-thread) 프로그래밍에서 하나의 객체를 여러 쓰레드가 동시에 접근할 수 있기 때문에 데이터의 일관성(consistency)을 유지하기 위해서는 공유되는 객체에 동기화(synchronization)가 필요하다. Vector와 Hashtable과 같은 구버전의 클래스들은 자체적으로 동기화 처.. 2021. 7. 11. 이전 1 ··· 115 116 117 118 119 120 121 ··· 142 다음