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
zheka24 [161]
3 years ago
6

All phones must have a way of making and then terminating a connection to the phone network; however the exact procedure for doi

ng so depends upon the nature of the phone (e.g. landline, cell phone, satellite phone). Write a abstract class, Phone, that contains a string instance variable, phoneNumber, a constructor that accepts a string parameter initializing the instance variable, an accessor method, getPhoneNumber, that returns the phoneNumber, a toString method that return the phoneNumber in the form
Computers and Technology
1 answer:
Aliun [14]3 years ago
6 0

Answer:

The code will be a java-script code

Explanation:

public abstract class Phone{

    private String phoneNumber ;

    public Phone  (String thePhoneNumber) {

        phoneNumber = thePhoneNumber ;

    }

    public  String getPhoneNumber ( ) {

        return phoneNumber ;

    }

public String toString (  ) {

    phoneNumber = "# (" + phoneNumber + ") " ;

    return phoneNumber ;

   }

public abstract boolean createConnection (Network status) ;

public abstract void closeConnection(  ) ;

}

You might be interested in
The Windows Net use command is a quick way to discover any shared resources on a computer or server. True or False
V125BC [204]
Yes it’s true the window net use command is a quick way to discover any shared resources on a computer or server
8 0
2 years ago
Write the definition of a void function that takes as input an integer and outputs two times the number if it is even; otherwise
KatRina [158]

Answer:

Written in C++

void number(int n){

if(n%2 == 0)

cout<<2 * n;

else

cout<<5 * n;

}

Explanation:

The programming language is not stated.

However, I answered using C++

This line defines the function as void

void number(int n){

This line checks if the number is even

if(n%2 == 0)

If yes, it doubles the number and prints the output

cout<<2 * n;

If otherwise,

else

It multiplies the number by 5 and prints the output

cout<<5 * n;

}

To call the function from main, use:

number(n);

Note than n must be declared as integer

See attachment

Download cpp
6 0
3 years ago
WHAT BIRD IS SHOWN ON THE ARM OF BLOODHOUND?
ruslelena [56]

Answer:

Looks like a raven to me

Explanation:

4 0
3 years ago
Read 2 more answers
Renting provides _________ flexibility but can lead to _________ costs in the long-term.
docker41 [41]
Renting provides greater flexibility but can lead to higher costs in the long term.
3 0
3 years ago
Read 2 more answers
How to create json object from variables javascript
tino4ka555 [31]
Not entirely sure what you want to achieve, but consider this program:

var a = 'foo';
var b = 'bar';

var c = { first : a, second : b };

console.log(JSON.stringify(c, null, 4));

A json object c is constructed using the values from variables a and b. Is this what you mean?
8 0
3 years ago
Other questions:
  • Which of the following is NOT an option in the comments group
    12·1 answer
  • Which of the following attacks seeks to introduce erroneous or malicious entries into a server's hostname-to-IP address cache or
    5·1 answer
  • Letter Frequency Write a function that will take a string and return a count of each letter in the string. For example, "my dog
    5·1 answer
  • "Which of the following is not an example of a project? Select one: a. Creating a website for a company b. Raising money for a d
    5·1 answer
  • What is lasso tool write the name of any modelling and animation software<br>​
    8·1 answer
  • Explain the principles of computer applications ​
    11·1 answer
  • drag each type of document to the correct location on the table. Drag each document to its respective category
    7·1 answer
  • Choose the appropriate software category for each specific application shown.
    11·1 answer
  • Which three options below describe typographic hierarchy?
    12·1 answer
  • What is a very important difference there between the wiring of an electromechanical thermostat and an electronic programmable t
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!