전체 글 (187) 썸네일형 리스트형 [자바] 정올 587 ~ 592 : 함수3 - 자가진단1~6 자가진단1 : 587 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); int i = 0; solution(n, i); } public static void solution(int n, int i){ if(i == n) return; System.out.println("recursive"); i++; solution(n, i); } } 자가진단2: 588 import java.util.Scanner; public class Main { public static void main(String[] a.. [자바] 정올 175 ~ 181 : 함수2 - 형성평가1~7 형성평가1 : 175 import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); Integer[] arr = new Integer[n]; for(int i = 0;i [자바] 정올 579 ~ 586 : 함수2 - 자가진단1~8 자가진단1 import java.util.Arrays; import java.util.Collections; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); Integer[] arr = new Integer[a]; for(int i = 0; i < a; i++) arr[i] = sc.nextInt(); arr_sort(arr); } public static void arr_sort(Integer[] arr){ Arrays.sort(arr, Collections.reverseOrder()); fo.. [자바] 정올 170 ~ 174 : 함수1 - 형성평가1 ~ 5 형성평가1 public class Main { public static void main(String[] args) { System.out.println("first"); pr(); System.out.println("second"); pr(); System.out.println("third"); pr(); } public static void pr(){ System.out.println("@@@@@@@@@@"); } } 형성평가2 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a =sc.nextInt(); int answe.. [자바] 정올 571 ~ 578 : 함수1 - 자가진단1 ~ 8 자가진단1 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); pr(n); } public static void pr(int n){ System.out.println("~!@#$^&*()_+|\n".repeat(n)); } } 자가진단2 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); wo.. [자바] 정올 160 ~ 169 : 배열2 - 형성평가1 ~ 10 형성평가1 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int val; int[] count = new int[7]; for(int i = 0; i < 10; i++){ val = sc.nextInt(); count[val] += 1; } for(int i = 1; i < 7; i++) System.out.println(i + " : " + count[i]); } } 형성평가2 import java.util.Scanner; public class Main { public static void main(String[] args) {.. [자바] 정올 564 ~ 570 : 배열2 - 자가진단1 ~ 7 자가진단1 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); char[] arr = new char[100]; int[] arr2 = new int[26]; char ch; int i; for(i = 0; i 90) break; arr[i] = ch; arr2[(int)ch - 65]++; } for(int j = 0; j < arr2.length; j++){ if(ar.. [자바] 정올 150 ~ 159 : 배열1 - 형성평가 1 ~ 10 형성평가1 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); char[] arr = new char[10]; for(int i =0; i =0; i--) System.out.print(arr[i] + " "); } } 형성평가2 import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new S.. 이전 1 ··· 6 7 8 9 10 11 12 ··· 24 다음