Free Oracle 1z0-830 Practice Test & Real Exam Questions
Which of the following suggestions compile?(Choose two.)
Correct Answer: B,D
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
Which of the following java.io.Console methods doesnotexist?
Correct Answer: E
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
Given:
java
interface SmartPhone {
boolean ring();
}
class Iphone15 implements SmartPhone {
boolean isRinging;
boolean ring() {
isRinging = !isRinging;
return isRinging;
}
}
Choose the right statement.
java
interface SmartPhone {
boolean ring();
}
class Iphone15 implements SmartPhone {
boolean isRinging;
boolean ring() {
isRinging = !isRinging;
return isRinging;
}
}
Choose the right statement.
Correct Answer: C
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
Which two of the following aren't the correct ways to create a Stream?
Correct Answer: B,D
Vote an answer
Which of the followingisn'ta correct way to write a string to a file?
Correct Answer: A
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
Given:
java
public static void main(String[] args) {
try {
throw new IOException();
} catch (IOException e) {
throw new RuntimeException();
} finally {
throw new ArithmeticException();
}
}
What is the output?
java
public static void main(String[] args) {
try {
throw new IOException();
} catch (IOException e) {
throw new RuntimeException();
} finally {
throw new ArithmeticException();
}
}
What is the output?
Correct Answer: D
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
Given:
java
var ceo = new HashMap<>();
ceo.put("Sundar Pichai", "Google");
ceo.put("Tim Cook", "Apple");
ceo.put("Mark Zuckerberg", "Meta");
ceo.put("Andy Jassy", "Amazon");
Does the code compile?
java
var ceo = new HashMap<>();
ceo.put("Sundar Pichai", "Google");
ceo.put("Tim Cook", "Apple");
ceo.put("Mark Zuckerberg", "Meta");
ceo.put("Andy Jassy", "Amazon");
Does the code compile?
Correct Answer: A
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
How would you create a ConcurrentHashMap configured to allow a maximum of 10 concurrent writer threads and an initial capacity of 42?
Which of the following options meets this requirement?
Which of the following options meets this requirement?
Correct Answer: D
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
Given:
java
double amount = 42_000.00;
NumberFormat format = NumberFormat.getCompactNumberInstance(Locale.FRANCE, NumberFormat.Style.
SHORT);
System.out.println(format.format(amount));
What is the output?
java
double amount = 42_000.00;
NumberFormat format = NumberFormat.getCompactNumberInstance(Locale.FRANCE, NumberFormat.Style.
SHORT);
System.out.println(format.format(amount));
What is the output?
Correct Answer: A
Vote an answer
Explanation: Only visible for Pass4Leader members. You can sign-up / login (it's free).
