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
Gnesinka [82]
3 years ago
5

Constructors have the same name as the ____.1. data members2. member methods3. class4. package

Computers and Technology
1 answer:
Svetradugi [14.3K]3 years ago
8 0

Answer:

(3) option is the correct answer.

Explanation:

Constructors need to initialize the object in the memory. "To declare the Constructor for any class the user needs to specify the constructor name which is already the class name". This is an object-oriented language guideline.

It is because the object is created by the name of the class and Constructor is used to allocate the memory for the object. hence Constructor is created by the name of the class.

For example--

                       class test //class name test

                      {

                               test() //created a constructor with class name "test"

                               {

                               }

                      }

In the above example class name and constructor name are same if it not then it will gives a error.

Another option is not valid for the answer to the above problem because-

  • Option 1 is wrong because, for any class, the data member is a type of variable, which is used to store the data and is accessed with the help of an object.
  • Option 2 is wrong because, for any class, member function is a type of user function used to accessed the variable and expressions.
  • Option 4 is wrong because, package is a set used to hold classes and interfaces.

You might be interested in
What is a graph,a chart then give similarities between graph and chart.​
Alik [6]

Answer:

A diagram showing the relation between variable quantities, typically of two variables, each measured along one of a pair of axes at right angles. A collection of points whose coordinates satisfy a given relation. A sheet of information in the form of a table, graph, or diagram. Normally graphs and charts in excel are very much similar to each other, but they are different, Graphs are mostly a numerical representation of data as it shows the relation of change in numbers that how one number is affecting or changing another, however, charts are the visual representation where categories may or may not be related to each other also how the information is displayed is different in both graphs and charts.

6 0
3 years ago
Read 2 more answers
What is a wireless network that provides communication over a short distance that is intended for use with devices that are owne
andrew11 [14]

Answer: personal area network

Explanation:

it can connect personal devices to make network, the personal network are phone,laptop,printer and soon in order to communicate.

3 0
3 years ago
Read 2 more answers
When using e-mail for business purposes, employees should _____.
harina [27]

Answer:use spell check

proofread messages

use appropriate punctuation

be brief

use correct grammar

Explanation:

3 0
3 years ago
Need ASAP
expeople1 [14]
The customer should consider buying the hard drive
3 0
3 years ago
Was communication always formal?
DaniilM [7]
No. Communication not always formal.
4 0
3 years ago
Other questions:
  • What products use fabric manipulation
    8·1 answer
  • The user can set their own computer hostname and username. Which stage of the hardware lifecycle does this scenario belong to?
    6·1 answer
  • Isaac was assigned to work on a computer in his company’s R&D department. While working on the system, Isaac received severa
    8·1 answer
  • You've just purchased 10 new notebook systems for your users. You are concerned that users will leave the systems on for long pe
    10·1 answer
  • X = 19 y = 5 print (x % y)
    11·1 answer
  • Assume that name has been declared suitably for storing names (like "Misha", "Emily" and "Sofia"). Assume also that stdin is a v
    6·1 answer
  • In this problem, you will fill in the code for a function count_digits(val) that takes a positive integer, val, and returns a li
    12·1 answer
  • A(an)_______is built-in preset calculation. <br>formula <br> function <br>equation <br>AutoSum​
    12·1 answer
  • Write an Algorithm to print only numbers from 10 to n times using iteration structure
    8·1 answer
  • Mention 5 types of assembly language​
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!