1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Llana [10]
3 years ago
14

Type the correct answer in the box. Use numerals instead of words. If necessary, use / for the fraction bar. What will be the ou

tput of the following code?
class Vehicle public static int counter = 0;
public int printCounter_val ) counter = counter + 1;
return counteri public class test
Vehicle public static void main(String args[l) f Vehicle v1=new vehicle();
v1.printCounter val Vehicle v2=new Vehicle() ;
system.out.printin (v2.printCounter_val )):
The output will be______
Computers and Technology
1 answer:
lord [1]3 years ago
8 0

Answer:

2

Explanation:

The output of the Java program is 2. The public Vehicle class is defined with the class variable 'counter'. When a Vehicle class object is instantiated, the counter variable increments by one.

In the program, the two instances of the class are created, incrementing the counter variable to two, the print statement outputs 2 as the result of the program.

You might be interested in
When did the mantle of the earth form
Musya8 [376]
It formed <span>about 4.5 billion years ago</span><span> </span>
5 0
2 years ago
Read 2 more answers
Which of the selections below represents a recursive query?
ElenaW [278]

Answer:

D. A DNS server asks another DNS server to resolve a domain name

Explanation:

DNS (Domain name system) queries are essentially of two types;

i. recursive address resolution

ii. iterative or non-recursive address resolution

=> In the <em>recursive address resolution</em>, which represents a recursive query, when a DNS server A, receives a request from a client and does not know how to resolve such request, the DNS server sends the query to another DNS server B on behalf of this client. DNS server B can either reply to the query with the actual answer or an error message. If it's an actual answer, it returns to the client. Otherwise, it queries another DNS server, say C.

=> In the <em>iterative address resolution</em>, once the DNS server A receives a request from the client, it tries to reply the client with the best answer it can give. If the DNS server A does not have an answer, it refers the client to another DNS server say B. In this case, the server A does not directly query the server B. Instead, it refers the client to the server B.

5 0
3 years ago
How many types of window in Qbasic​
kirza4 [7]

Answer:

QBasic consists of two windows: Program Window: The window titled as 'Untitled' is the program window. It is the place where program/code is written. Immediate Window: The window below Program Window titled as 'Immediate' is the immediate window.

5 0
3 years ago
Describe how being a global citizen in the world of advanced technology can be beneficial to your success in meeting your person
olga55 [171]

Answer:

well you could have more options of careers and more possibilities, online jobs can pay more and give more experience to the employees

7 0
3 years ago
State why hexadecimal is used to display the error code
maxonik [38]
“Hexadecimal uses digits that more closely resemble our usual base-10 counting system and it's therefore easier to decide at a glance how big a number like e7 is as opposed to 11100111. Higher information density. With 2 hexadecimal digits, we can express any number from 0 to 255.”
7 0
3 years ago
Other questions:
  • What is the function of series-parallel circuit
    9·1 answer
  • Why has unicode become the standard way of converting binary to text
    7·1 answer
  • 1. Write a program to prompt the user to enter a single character and respond back whether or not the character is valid dna. 2.
    12·1 answer
  • In steps<br> Urgent please
    14·1 answer
  • After clicking the Start button on your computer screen desktop, what option would you then select to examine system components
    10·2 answers
  • Describe how computer is in the last 35 years
    6·1 answer
  • Why does the phrase "compatibility mode” appear when opening a workbook?
    6·2 answers
  • What is not true about contracts?
    12·2 answers
  • Number Array Class
    5·1 answer
  • You are developing a Website that is going to be viewed extensively on smartphones and tablets. Which of the following should yo
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!