- Today
- Total
Notice
Recent Posts
Codemental
[baekjoon][Java] 2741번 - N 찍기 본문
반응형
문제
제출답안 1(2022.07.22)
import java.io.*;
public class Main {
public static void main(String[] args) throws NumberFormatException, IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int num = Integer.parseInt(br.readLine());
br.close();
for(int i = 1 ; i <=num; i++) {
System.out.println(i);
}
}
}
채점결과 1(2022.07.22)
제출답안 2(2022.07.22)
import java.io.*;
public class Main {
public static void main(String[] args) throws NumberFormatException, IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int num = Integer.parseInt(br.readLine());
br.close();
BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(System.out));
for(int i = 1 ; i <=num; i++) {
bw.write(i + "\n");
}
bw.flush();
bw.close();
}
}
채점결과 2(2022.07.22)
'Java > 코딩테스트(baekjoon)' 카테고리의 다른 글
[baekjoon][Java] 11021번 - A+B - 7 (0) | 2022.07.22 |
---|---|
[baekjoon][Java] 2742번 - 기찍 N (0) | 2022.07.22 |
[baekjoon][Java] 2941번 - 크로아티아 알파벳 (0) | 2022.07.21 |
[baekjoon][Java] 5622번 - 빠른 A+B (0) | 2022.07.20 |
[baekjoon][Java] 2908번 - 상수 (0) | 2022.07.20 |