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
olga_2 [115]
3 years ago
11

cellPhoneBill(m,tx)Write the function cellPhoneBill()that takes two int m and txas input and returns a float.The function takes

total number of minutes and text messages that user spends in a particular month and returns the bill amount. These is the policy of the carrier company:
Computers and Technology
1 answer:
lidiya [134]3 years ago
4 0

Answer:

The solution code is written in C++

  1. float cellPhone(int m, int tx){
  2.    float COST_PER_MIN = 0.1;
  3.    float COST_PER_MESSAGE = 0.2;
  4.    
  5.    float bill_amount = m * COST_PER_MIN + tx * COST_PER_MESSAGE;
  6.    
  7.    return bill_amount;
  8. }

Explanation:

Firstly, declare a function named cellPhone() that takes two input parameters, m and tx (Line 1).

Since the policy of the carrier company is not given in the question, I make a presumption that the cost per minutes is $0.10 and the cost per message is $0.20 (Line 2- 3).

Next, apply the formula m * COST_PER_MIN + tx * COST_PER_MESSAGE to calculate the total bill (Line 5) and return the bill_amount as function output (Line 7).

You might be interested in
To change the backround color of a page, which tab would you use?
ivann1987 [24]
I have concluded the answer is a
4 0
3 years ago
Read 2 more answers
Is the number of hits to a website in a daynumber of hits to a website in a day a discrete random​ variable, a continuous random
marissa [1.9K]

Answer:

The correct answer to the following question will be "It is a discrete random variable".

Explanation:

A variable that assumes algebraic expressions defined by a randomized occurrence result, is a Random variable.

  • There are several potential or possible values for a single randomized variable.
  • A discrete random variable's chances for each value is between 0 (zero) and 1 (One), as well as the total amount among all possible outcomes, is equitable to 1.

So, a Discrete random variable is the right answer.

3 0
3 years ago
Read 2 more answers
Which file extension indicates a Microsoft Excel document?
VikaD [51]
XLSX is the extension for an excel document.

3 0
3 years ago
What are Layers in computer class 7. no scams please​
Bad White [126]

Answer:

This is your answer please check this ✔

7 0
2 years ago
Read 2 more answers
A marketing company setting up a new office in the city. Which type of contract should I sign for periodic maintenance of their
Fed [463]

Answer:

Fixed-term contract is most feasible in this scenario.

Explanation:

8 0
3 years ago
Other questions:
  • Every application program has a _______________ segment
    6·1 answer
  • Modify the code below to do the following:
    12·1 answer
  • A ____ object is used to hold data that is retrieved from a database via the OleDbDataAdapter connection. a. DataRecord b. DataS
    12·2 answers
  • In an information systems framework, ________ is the bridge between the computer side on the left and the human side on the righ
    14·1 answer
  • Anyone wanna hop on 1v1.lol<br> party code : usfhb6
    12·2 answers
  • Match each method of communication with its intended purpose.
    14·1 answer
  • ASAP BRAINLIEST!!!
    6·1 answer
  • By limiting the number of times a person can use a type of software before registering as the authorized owner of that software,
    15·1 answer
  • What is the action of extracting data fragments and then reassembling them in order to recover a file?.
    10·1 answer
  • Write a function called st_dev. st_dev should have one
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!