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
Mashcka [7]
3 years ago
7

A constructor can be overloaded with more than one function which has the same name but with what two different things

Computers and Technology
1 answer:
andreyandreev [35.5K]3 years ago
5 0
<h2>Answer:</h2>

i. Number of parameters

ii. Type of parameters

<h2>Explanation:</h2>

When there are two or more constructors, definitely with the same name, in a given class, then the constructors are said to be overloaded. An overloaded constructor appears declared many times in a class but each time with different number of parameters and/or type of parameters.

For example, given a class Test, the following combination of constructors can exist;

i. public Test(int x){

   

 }

ii. public Test(String m){

     

  }

iii. public Test(int a, String b){

 

}

<em>The following should be noted;</em>

In the case of combination (i) and (ii), the constructors have the same number of parameters but different type of parameter. In other words, they both have 1 parameter but while the first one has a parameter type of <em>int</em>, the second has a parameter type of <em>String</em>.

In the case of combination (ii) and (iii), the constructors have different number of parameters and of course different type of parameters. In other words, the second constructor has 1 parameter of type <em>String</em> while the third constructor has 2 parameters of types <em>int</em> and <em>String</em>.

You might be interested in
Which is the most visual social media site?
Aleks04 [339]
Enge extrapolated this analysis across the 2.2 billion<span> users on Google and concluded that while the “active profiles” on Google+ amount to </span>111 million<span> users, only 6.7 million users have 50 or more posts ever, and only 3.5 million have 50 or more posts in the last 30 days</span>
3 0
3 years ago
Controlling inflation is the job of the __________________.
n200080 [17]
B. Federal Reserve................
8 0
3 years ago
Read 2 more answers
After a failover cluster is created, which of the following is a task to be performed when configuring the failover cluster? (Ch
Lynna [10]

Answer: (B) Configure the cluster networks

               (C) Configure the quorum model

Explanation:

 When the fail-over cluster has been created then, configure the cluster network and quorum model tasks performed during configuring the fail-over cluster.

The quorum model are flexible in the window server. We can configure the quorum model when we need to modified the quorum model configuration for the cluster. The software cluster are automatically configure quorum model for the new cluster that is based on the availability of the share storage.

When configuring the fail-over cluster we can perform various cluster network tasks in the system.  

 

 

 

8 0
3 years ago
In PyCharm, write a program that prompts the user for their name and age. Your program should then tell the user the year they w
Neporo4naja [7]

Answer:

def main():

   name = input("What is your name? ")

   if not name == "" or "":

       age = int(input("What is your age? "))

       print("Hello " + name + "! You were born in " + str(2021 - age))

main()

Explanation:

Self explanatory

5 0
3 years ago
____ refers to the ability of one computing device (a desktop computer, portable computer, or smartphone, for example) on a netw
SCORPION-xisa [38]
<span>Presence technology is the answer</span>
8 0
3 years ago
Other questions:
  • How technology bacome the mode of revealing​
    10·1 answer
  • The class at the top of exception class hierarchy is ..........................
    12·1 answer
  • Look up and list the number of a local taxi or car service in your community. Include the company name and telephone number.
    13·1 answer
  • Compose a program to examine the string "Hello, world!\n", and calculate the total decimal numeric value of all the characters i
    7·1 answer
  • To reduce costs and the environmental impact of commuting, your company decides to close a number of offices and to provide supp
    14·1 answer
  • ou and a friend decide to watch a movie on your computer. The movie is saved on a second hard drive on your system. When you are
    7·1 answer
  • You have to sort 1 GB of data with only 100 MB of available main memory. Which sorting technique will be most appropriate?
    5·1 answer
  • what is one example of the decomposers taking from the ecosystem and one of them giving to the ecosystem
    14·1 answer
  • 12. In Justify the text is aligned both to the right and to the left margins, adding extra space between words as necessary *
    13·2 answers
  • How to connect two routers wirelessly to extend range.
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!