본문 바로가기

PROGRAMMING CODE221

[BAEKJOON] No.2445 JAVA 별찍기 -8 ​ import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); for(int i=1; i0; k--) System.out.print("*"); for(int j=1; j0; k--) System.out.print("*"); System.out.println(); } sc.close(); } } 잘돌아가는데 왜 틀렸다하누,, import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner s.. 2021. 10. 14.
[BAEKJOON] No.2444 JAVA 별찍기 -7 ​ import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); for(int i=1; i0; j--) System.out.print(" "); for(int k=1; k 2021. 10. 14.
[BAEKJOON] No.2884 JAVA 알람시계 ​ ​ ​ import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int H = sc.nextInt(); int M = sc.nextInt(); if(M=45) System.out.println(H+" "+(M-45)); sc.close(); } } 2021. 10. 14.
[BAEKJOON] No.1000 JAVA ​ A+B ​ ​ ​ import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); System.out.println(a+b); sc.close(); } } *백준 자바 제출시 클래스 이름을 반드시 "Main"으로 해야함 2021. 10. 14.
[BAEKJOON] No.2460 C++ 지능형 기차 2 ​ ​ ​ #include using namespace std; int main(int argc, const char * argv[]) { int arr[11][2],max=0,num=0; for(int i=0; i arr[i][j]; } } for(int i=0; imax) max=num; } cout 2021. 10. 14.
[BAEKJOON] No.2953 C++ 나는 요리사다 ​ ​ ​ #include using namespace std; int main(int argc, const char * argv[]) { int arr[5][4],max=0,sum=0,idx=0; for(int i=0; i arr[i][j]; } } for(int i=0; i 2021. 10. 14.