subject

What is result of executing the following code? public class Question11 {
private static int x = 1;
public static void main(String[] args) {
int x = 5;
System. out. printf("local x in main is %d%n", x);
useLocalVariable();
useField();
useLocalVariable();
useField();
System. out. printf("%nlocal x in main is %d%n", x);
}
public static void useLocalVariable() {
int x = 25;
System. out. printf(
"%nlocal x on entering method useLocalVariable is %d%n", x);
++x;
System. out. printf(
"local x before exiting method useLocalVariable is %d%n", x);
}
public static void useField() {
System. out. printf(
"%nfield x on entering method useField is %d%n", x);
x *= 10; // modifies class Scope’s field x
System. out. printf(
"field x before exiting method useField is %d%n", x);
}
}

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 14:30
Select the correct answer. what does it indicate when a website displays https instead of http? a. the website is secure. b. there is no secure sockets layer. c. the secure sockets layer is hidden. d. the website is not secure.
Answers: 1
question
Computers and Technology, 23.06.2019 18:00
What can a word user do with the customize ribbon dialog box? check all that apply. minimize the ribbon add a new tab to the ribbon remove a group from a tab add a group to a tab choose which styles appear choose which fonts appear choose tools to appear in a group
Answers: 1
question
Computers and Technology, 23.06.2019 22:00
Jackson, who works in the finance department of a company, is holding a seminar for other employees on how to file taxes. only three employees sign up to attend the seminar. which device can he use to share his presentation with a group of three employees?
Answers: 1
question
Computers and Technology, 23.06.2019 22:30
The output voltage of a power supply is assumed to be normally distributed. sixteen observations are taken at random on voltage are as follows: 10.35, 9.30, 10.00, 9.96, 11.65, 12.00, 11.25, 9.58, 11.54, 9.95, 10.28, 8.37, 10.44, 9.25, 9.38, and 10.85
Answers: 1
You know the right answer?
What is result of executing the following code? public class Question11 {
private static int...
Questions
question
Mathematics, 17.01.2020 00:31
question
History, 17.01.2020 00:31
question
Physics, 17.01.2020 00:31
question
Mathematics, 17.01.2020 00:31
Questions on the website: 13722359