1z1-830 試験問題 1
与えられた条件:
ジャワ
パブリック静的void main(String[] args) {
試す {
新しい IOException() をスローします。
} キャッチ (IOException e) {
新しい RuntimeException() をスローします。
} ついに {
新しい ArithmeticException() をスローします。
}
}
出力は何ですか?
ジャワ
パブリック静的void main(String[] args) {
試す {
新しい IOException() をスローします。
} キャッチ (IOException e) {
新しい RuntimeException() をスローします。
} ついに {
新しい ArithmeticException() をスローします。
}
}
出力は何ですか?
1z1-830 試験問題 2
与えられた条件:
ジャワ
パッケージ com.vv;
java.time.LocalDate をインポートします。
パブリッククラスFetchService {
パブリック静的void main(String[] args)は例外をスローします{
FetchService サービス = 新しい FetchService();
文字列 ack = service.fetch();
LocalDate 日付 = service.fetch();
System.out.println(ack + " the " + date.toString());
}
パブリック文字列フェッチ(){
「ok」を返します。
}
パブリックLocalDateフェッチ(){
LocalDate.now() を返します。
}
}
出力はどうなりますか?
ジャワ
パッケージ com.vv;
java.time.LocalDate をインポートします。
パブリッククラスFetchService {
パブリック静的void main(String[] args)は例外をスローします{
FetchService サービス = 新しい FetchService();
文字列 ack = service.fetch();
LocalDate 日付 = service.fetch();
System.out.println(ack + " the " + date.toString());
}
パブリック文字列フェッチ(){
「ok」を返します。
}
パブリックLocalDateフェッチ(){
LocalDate.now() を返します。
}
}
出力はどうなりますか?
1z1-830 試験問題 3
最終クラスについて正しい記述は次のうちどれですか?
1z1-830 試験問題 4
与えられた条件:
ジャワ
パブリッククラス SpecialAddition は Addition を拡張し、Special を実装します {
パブリック静的void main(String[] args) {
System.out.println(新しいSpecialAddition().add());
}
整数追加() {
--foo + bar-- を返します。
}
}
クラス追加 {
整数 foo = 1;
}
インターフェース Special {
整数バー = 1;
}
何が印刷されますか?
ジャワ
パブリッククラス SpecialAddition は Addition を拡張し、Special を実装します {
パブリック静的void main(String[] args) {
System.out.println(新しいSpecialAddition().add());
}
整数追加() {
--foo + bar-- を返します。
}
}
クラス追加 {
整数 foo = 1;
}
インターフェース Special {
整数バー = 1;
}
何が印刷されますか?
1z1-830 試験問題 5
次のうち、ストリームを作成する正しい方法ではない 2 つはどれですか。