Network disconnected
Description
주어진 코드가 아래와 같이 출력되게 만들고 싶습니다. 빈칸에 알맞은 타입을 채워 문제를 해결해 보세요.
false
a
20
2147483648
힌트: 아래의 예를 참고하여 문제를 해결하세요.
boolean isFun = true;
char c ='f';
int x = 59;
// long 타입 값에는 소문자 l이나 대문자 L을 붙여야 합니다.
long big = 3456789L;
// float 타입 값에는 소문자 f나 대문자 F를 붙여야 합니다.
float f = 32.5f;
double d = 23.34;
- int형 변수는 최대 2147483647까지 담을 수 있습니다. 더 큰 값을 사용하고 싶다면 long형을 사용하세요.
Question type: Fill in the blank
- You need to fill in the blank with the appropriate code.
- You cannot modify the given code.
- An error message will appear in the result if you leave the blank empty.
1
2
3
4
5
6
7
8
9
10
11
12
13
public class PrimitiveDataTypeExam {
public static void main(String[] args) {
isFun = false;
charValue = 'a';
intValue = 20;
longValue = 2147483648L;
System.out.println(isFun);
System.out.println(charValue);
System.out.println(intValue);
System.out.println(longValue);
}
}
Result
Stop
Result of [Run Test] or [Submit] will be displayed here
내가 제출한 코드가 왜 틀렸는지 프로그래머스 AI에게 물어보세요.
제출 후 채점하기를 눌러 30점 이상인 경우 물어볼 수 있어요.
베타 기간 동안에는 한 문제당 1번만 물어볼 수 있어요.
베타 기간 동안에는 한 문제당 1번만 물어볼 수 있어요.