분류 전체보기

    [SW expert Academy] SWEA 3408번 세가지 합 구하기 자바(Java)

    [D3] 세가지 합 구하기 - 3408 문제 링크 성능 요약 메모리: 45,904 KB, 시간: 315 ms, 코드길이: 444 Bytes 제출 일자 2023-10-31 10:14 출처: SW Expert Academy, https://swexpertacademy.com/main/code/problem/problemList.do import java.util.Scanner; class Solution { public static void main(String args[]) throws Exception { Scanner sc = new Scanner(System.in); int T = sc.nextInt(); for(int tc = 1; tc

    [SW expert Academy] SWEA 5789번 현주의 상자 바꾸기 자바(Java)

    [D3] 현주의 상자 바꾸기 - 5789 문제 링크 성능 요약 메모리: 108,608 KB, 시간: 690 ms, 코드길이: 677 Bytes 제출 일자 2023-10-31 09:47 출처: SW Expert Academy, https://swexpertacademy.com/main/code/problem/problemList.do import java.util.Scanner; class Solution { public static void main(String args[]) throws Exception { Scanner sc = new Scanner(System.in); int T = sc.nextInt(); for(int tc = 1; tc

    [SW expert Academy] SWEA 7272번 안경이 없어! 자바(Java)

    [D3] 안경이 없어! - 7272 문제 링크 성능 요약 메모리: 51,044 KB, 시간: 334 ms, 코드길이: 1,096 Bytes 제출 일자 2023-10-31 09:29 출처: SW Expert Academy, https://swexpertacademy.com/main/code/problem/problemList.do import java.util.Scanner; class Solution { public static void main(String args[]) throws Exception { Scanner sc = new Scanner(System.in); int T = sc.nextInt(); String noHole = "CEFGHIJKLMNSTUVWXYZ"; String oneHole..

    [SW expert Academy] SWEA 4047번 영준이의 카드 카운팅 자바(Java)

    [D3] 영준이의 카드 카운팅 - 4047 문제 링크 성능 요약 메모리: 20,696 KB, 시간: 130 ms, 코드길이: 1,566 Bytes 제출 일자 2023-10-30 21:40 출처: SW Expert Academy, https://swexpertacademy.com/main/code/problem/problemList.do import java.util.*; class Solution { public static void main(String args[]) throws Exception { Scanner sc = new Scanner(System.in); int T = sc.nextInt(); for(int tc = 1; tc

    [SW expert Academy] SWEA 8016번 홀수 피라미드 자바(Java)

    [D3] 홀수 피라미드 - 8016 문제 링크 성능 요약 메모리: 19,712 KB, 시간: 130 ms, 코드길이: 347 Bytes 제출 일자 2023-10-30 21:03 출처: SW Expert Academy, https://swexpertacademy.com/main/code/problem/problemList.do import java.util.Scanner; class Solution { public static void main(String args[]) throws Exception { Scanner sc = new Scanner(System.in); int T = sc.nextInt(); for(int tc = 1; tc

    [SW expert Academy] SWEA 3750번 Digit sum 자바(Java)

    [D3] Digit sum - 3750 문제 링크 성능 요약 메모리: 107,000 KB, 시간: 653 ms, 코드길이: 520 Bytes 제출 일자 2023-10-30 19:58 출처: SW Expert Academy, https://swexpertacademy.com/main/code/problem/problemList.do import java.util.Scanner; class Solution { public static void main(String args[]) throws Exception { Scanner sc = new Scanner(System.in); int T = sc.nextInt(); for(int tc = 1; tc

    [SW expert Academy] SWEA 5456번 의석이의 세로로 말해요 자바(Java)

    [D3] 의석이의 세로로 말해요 - 5356 문제 링크 성능 요약 메모리: 23,804 KB, 시간: 164 ms, 코드길이: 748 Bytes 제출 일자 2023-10-30 19:47 출처: SW Expert Academy, https://swexpertacademy.com/main/code/problem/problemList.do import java.util.Scanner; class Solution { public static void main(String args[]) throws Exception { Scanner sc = new Scanner(System.in); int T = sc.nextInt(); for(int tc = 1; tc i) System.out.print(strs[j].cha..

    [백준] 1202번 : 보석 도둑 Gold2(골드2) - JAVA[자바]

    [Gold II] 보석 도둑 - 1202 문제 링크 성능 요약 메모리: 326064 KB, 시간: 2880 ms 분류 자료 구조, 그리디 알고리즘, 우선순위 큐, 정렬 제출 일자 2023년 10월 30일 14:33:36 문제 설명 세계적인 도둑 상덕이는 보석점을 털기로 결심했다. 상덕이가 털 보석점에는 보석이 총 N개 있다. 각 보석은 무게 Mi와 가격 Vi를 가지고 있다. 상덕이는 가방을 K개 가지고 있고, 각 가방에 담을 수 있는 최대 무게는 Ci이다. 가방에는 최대 한 개의 보석만 넣을 수 있다. 상덕이가 훔칠 수 있는 보석의 최대 가격을 구하는 프로그램을 작성하시오. 입력 첫째 줄에 N과 K가 주어진다. (1 ≤ N, K ≤ 300,000) 다음 N개 줄에는 각 보석의 정보 Mi와 Vi가 주어진다..