Write a program that calculates the amount of money a person would earn over a period of time if his or her salary is on one penny the first day, two pennies the second day and continues to double each day. The program should ask the user for the number of days. Display a table showing what the salary was for each day, then show the total pay at the end of the period. The output should bd displayed in a dollar amount, not the number of pennies. Must use for loop statement. Need to check the input value is correct, otherwise an error message is displayed. Display a nicely formatted table. Display the salary in dollar and cents

Answers

Answer 1

The program that calculates the amount of money a person would earn over a period of time if his or her salary as well as other factors inclusive is written below.

What is the program about?

The raw form of the program is:

#include <iostream>

using namespace std;

int main(){

   const int increment=2;

   int day;

   float penny=.01,

          total=0.0;

   cout <<"How many days have you worked? ";

   cin  >>day;

   while (day<1){

       cout<<"The number must be greater than 1.\n";

       cout<<"Enter again: ";

       cin >> day;

   }

   for (int i=1; i<=day;i++){

       total+=penny;

       cout <<" Day "<< i <<" "<< " $"<<penny<<endl;

       penny*=increment;

   }

    cout<<"Total salary for  "<<day <<" days = $" <<total<<endl;

Learn more about program from

https://brainly.com/question/23275071

#SPJ1


Related Questions

Types in java are divided into two categories. the primitive types are boolean, byte, char, short, int, long, float and double. all other types are ________ types

Answers

types in java are divided into two categories. the primitive types are boolean, byte, char, short, not, long, float, and double. all other types are REFERENCE types

What are the real-life applications of coding? any smart person who can give this ans

Answers

Answer:

Coding is used for a ton of different things. It can be used to create websites, video games, and apps. It is also an essential part of artificial intelligence and machine learning. Coding is a way to create computer programs that have a sequence of instructions for the computer to execute.

Explanation:

Research the history of Internet in computers

Answers

Answer:

This allowed different kinds of computers on different networks to "talk" to each other. ARPANET and the Defense Data Network officially changed to the TCP/IP standard on January 1, 1983, hence the birth of the Internet. All networks could now be connected by a universal language.

_____ drives are storage drives that contain both solid-state storage and hard disks in an attempt to gain the speed and power of ssds while still having the low cost and storage capacity of hard drives.

Answers

Answer:

Hybrid drives are storage drives that contain both solid-state storage and hard disks in an attempt to gain the speed and power of ssds while still having the low cost and storage capacity of hard drives.

The first part of an ethernet frame is known as the:

Answers

the first part of the ethernet frame is called the preamble

You work as the IT administrator for a growing corporate network. You are in the process of creating an iSCSI storage area network (SAN) on the CorpisCSI server. The server is currently connected to the network using an Ethernet cable. To increase the server's performance, yoru have decided to replace the existing Ethernet connection with a fiber optic connection. In this lab, your task is to complete the following: . Connect the CorpisCSI server to the switch using the appropriate fiber optic cable. . Examine the port types on the switch. Examine the server's fiber optic NIC. . When connecting the server, use the color coding on the end of the fiber optic cable to identify the Tx and Rx connection ends Connector A (red) Tx. - Connector B (black) is Rx. . Remove the server's previous Ethernet network connection and place the Ethernet cable on the Shelf. . Verify that the server is connected to the network through the fiber optic connection. C When connecting fiber optic cables, the transmit (T) port on one device is connected to the receive (Rx) port on the other device. The fiber cables in this lab have already had their Rx and Tx connectors switched as necessary. You can view component information in the Details window on the Specification tab

Answers

The steps in the above scenario are:

Connect to an iSCSI target:Then  Create a volume:

How do you Connect to an iSCSI target?

This can be done by:

Select CORPSERVER from Hyper-V Manager, Make sure to Maximize the window to view all virtual machines.Then Right-click CorpFiles16 and select Connect.Use the Server Manager on CorpFiles16 to select Tools > iSCSI Initiator.Via the Target field, enter the server name of the target server.Then click.Select Quick Connect and then Done and then OK.

Note that the steps in the above scenario are:

Connect to an iSCSI target:Then  Create a volume:

Learn more about IT admin from

https://brainly.com/question/26096799

#SPJ2

What is exactly meant by the term coding in context of computer science?

Answers

Answer:

writing instructions for the computer that the computer can interpret

Explanation:

This is about a software called GIMP

Answers

Answer:

The answer is Stroke

Explanation:

Stroke outlines objects on a layer

Answer:

The correct answer is Stroke.

Explanation:

Go to the Edit menu now and from here, click on the Stroke Selection option. A dialog box will open up where you need to select the Stroke Line option and then set up various options like solid line, line style, dash pattern, line width, etc. After setting up these options, press the Stroke option, and wooo u did it!

Hope this helps:) Goodluck!

A company will be able to obtain a quantity discount on component parts for its three products, X1, X2 and X3 if it produces beyond certain limits. To get the X1 discount it must produce more than 50 X1's. It must produce more than 60 X2's for the X2 discount and 70 X3's for the X3 discount. Which of the following pair of constraints enforces the quantity discount relationship on X3? a. X31 ? M3Y3 , X32 ? 50Y3 b. X31 ? M3Y3 , X31 ? 50 c. X32 ? (1/50)X31 , X31 ? 50 d. X32 ? M3Y3 , X31 ? 50Y3

Answers

The  pair of constraints enforces the quantity discount relationship on X3 is X32 ≤ M3Y3 and X31 ≥ 70Y3.

What is Relationship discount?

Relationship discounts especially on mortgages are known to be special loan terms that is said to be offered by financial institutions offer if a person have different types of accounts with them.

Note that The  pair of constraints enforces the quantity discount relationship on X3 is X32 ≤ M3Y3 and X31 ≥ 70Y3 as it best tell what it is about.

Learn more about  discount relationship from

https://brainly.com/question/10286547

#SPJ4

when you start a new, blank document, you usually end up changing the font to arial 11.5 point. how can you make these settings the default for this and all future new documents?

Answers

The fonts setting can be change to default by opening the format menu, after that click Font, and then click the Font tab. Make the needed changes that you want, and then click Default.

What is font?

A font is a set of printable or displayable text character s in a specific style and size.

These are the complete set of character like numbers, letters, and symbols/icon within a typeface, which is the design of the characters.

Hence, we can easily change the fonts setting to default.

Learn more about fonts here,

https://brainly.com/question/14934409

#SPJ1

Creating a map of your current knowledge is called __________. a. critical reading c. pre-questioning b. collaborative learning d. concept-mapping please select the best answer from the choices provided a b c d

Answers

Creating a map of your current knowledge is called  Concept-mapping. Check more about  Concept-mapping below.

What is concept mapping?

Concept maps are known to be visual depiction of information or human knowledge. They can be shown on a charts, graphic organizers, etc.

Therefore, Creating a map of your current knowledge is called  Concept-mapping as it involves bringing out one's intellectual.

Learn more about knowledge from

https://brainly.com/question/24621985

#SPJ4

Government entities may pressure upstream Internet service providers to _____. a. track and monitor the Internet activities of individuals b. accept defamation or copyright infringement claims c. immediately take down particular hosted material d. deregister domains because of their hosted content

Answers

Explanation:

The graph of y = √x is reflected in the y-axis, is horizontally stretched by a factor of 2, shifted 3 units up and 1 unit left. What is the equation of the transformed graph?

Original: y = √(x)

Reflected in the y-axis: y = √(-x)

Horizontally stretched by a factor of 2: y = √(-x/2)

Shifted 3 units up: y = 3 + √(-x/2)

And 1 unit left: y = 3 + √(-(x+1)/2)

what is the full meaning of I.C.T​

Answers

Answer:

information communications technology

Answer:

The infrastructure and components that enable modern computing is known as I.C.T (information and communications technology).

Although there is no single, universal definition of I.C.T, it is widely understood to refer to all devices, networking components, applications, and systems that when used together allow people and organizations (i.e., businesses, nonprofit organizations, governments, and criminal enterprises) to interact in the digital world.

"Computer Science is no more about computers
than astronomy is about telescopes"
- Edsger W. Dijkstra

Answers

Answer:

si

Explanation:

you want to be able to restrict values allowed in a cell and need to create a drop-down list of values from which users can choose. which feature should you use?

Answers

The  feature to restrict values allowed in a cell and need to create a drop-down list of values from which users can choose in the above scenario is data validation.

What is data validation?

Data validation is a term that connote the act of monitoring the truthfulness and quality of source data before one can make use of it, importing or even  process data with it.

Note that The  feature to restrict values allowed in a cell and need to create a drop-down list of values from which users can choose in the above scenario is data validation as it ensure that users can make their own choice.

Learn more about data validation from

https://brainly.com/question/27138101

#SPJ1

Mille gets a text from her friend asking if she wants to come over. It seems like a bit of a hassle to go to her friend's house, especially when they
could watch online videos together and talk over the phone. What is the BEST advice for Millie?
OA. Her friend will probably be relieved If she does not come over.
OB. They should just say whatever they want to say to each other over social media.
OC. It will be a more positive experience if she spends time with her friend in person.
OD. If they are doing the same activities virtually as they would if they were together, it does not make much difference.

Answers

Answer:

OC. It will be a more positive experience if she spends time with her friend in person.

Explanation:

You should always spend time with people in person rather than online whenever you get the chance.

At Universal Containers, the sales managers would like Opportunities that have NOT been updated in the past 30 days to automatically be flagged. How should a System Administrator implement this requirement

Answers

The System Administrator implement and Create a formula field to calculate the time since last update and display an image of a red flag if it meets the defined criteria.

What is a  Formula field?

This is known to be a read-only fields that often calculate a value through the use of other fields or a given  formula.

Note that The System Administrator implement his requirement and Create a formula field to calculate the time since last update and display an image of a red flag if it meets the defined criteria.

Learn more about System Administrator  from

https://brainly.com/question/27129590

#SPJ1

You have inserted a video on a slide and want the video to automatically start two seconds after the associated slide appears. How can you accomplish this?.

Answers

To be able to automatically start two seconds after the associated slide appears, it is better to use animation timings.

What is animation timing in PowerPoint?

The timings or the Duration option is known to be an option that informs the PowerPoint how long it will take for the slide to complete or for the text to show up on the screen.

Based on the above, To be able to automatically start two seconds after the associated slide appears, it is better to use animation timings.

Learn more about animation from

https://brainly.com/question/18260878


#SPJ1

what are trends in GPS ? ​

Answers

Answer:

New Trends in GPS & Telematics in 2021 and Beyond - Rewire Security. Real-time location tracking systems for cars, vans, motorcycles, lorries, wired or plug & play options—battery-powered GPS tracking systems with magnets attached to flat metal surfaces such as containers.

Explanation:

John is using a spreadsheet program. He needs to select two cells that are non-adjacent to one another. He is currently holding down the "Shift" key while clicking on the two cells. Interpret John's mistake.

John is using a right click when he should be using a left click

John should be holding the "Alt" key instead of the "Shift" key

John is not making any mistakes

John should be holding the "Ctrl" key instead of the "Shift" key

Answers

Answer:

John should be holding down the "Ctrl" key instead of the "Shift" key.

Explanation:

"Ctrl" key must be held down when selecting multiple cells, not "Shift" key.

Hope this helps!

Answer:

John should be holding the "Ctrl" key instead of the "Shift" key

Explanation:

A student wants to check six websites. Four of the websites are social and two are school-related. After checking just two sites, she has to leave for school. What is the approximate probability that she checked a social website first, then a school-related website?.

Answers

The approximate probability that she checked a social website first, then a school-related website is known to be 0.267

What is the check about?

In the above scenario, there are:

Total number of websites = 6

Number of school websites = 2

Number of social websites = 4

When she checks the social website first, the probability of checking a social website  is said to be 4/6

If one social website is checked, she is left with 3 social website and 2 school websites. So now the total number of websites will be 5.

The probability that the 2nd website that she checks is school related will be = 2/5

Therefor, the approximate probability that she checked a social website first, then a school-linked website is =

4/6 x 2/5

= 0.267

Therefore, the answer will be  0.267 probability level.

Learn more about websites from

https://brainly.com/question/10475324

#SPJ3

Every javafx main class __________. group of answer choices implements javafx.application.applicatio extends javafx.application.application overrides start(scene s) method overrides start() method

Answers

Two concepts central to JavaFX are a stage and a scene.

A website implements a sequential menu (as shown in the diagram) that indicates the relative page that the visitor is on in the website. Which planning phase covers this aspect?

A. Wireframe
B. Browsing functionality
C. Content
D. Page description diagrams

Answers

Answer:

Letter B. Browsing Functionality

Explanation: I just did this question

You have the following code:
----------------------------------------------------------------------------------------------
fruit_list = ["strawberries", "bananas", "apples", "grapes"]
total_cost = 0
for fruit in fruit_list:
if fruit in ["apples","bananas"]:
total_cost += 3
elif fruit == "cantaloupe":
total_cost += 5
elif fruit in ["raspberries","strawberries","grapes"]:
total_cost += 4
-------------------------------------------------------------------------------------------------

What will be the value of total_cost?

A.13
B.14
C.15
D.7

Answers

Answer:

7

Explanation:

We already have the functions that tells us how much to add. If you add all this, you will get 12. HOWEVER because cantaloupe is in the list, the computer does not count that. So if we add that again without 5(how much the cantaloupe costs), we get 7.

The internet service that allows users to navigate among many pages is.

Answers

Answer:

The world wide web

Explanation:

The world wide web is a hypertext information system that links internet documents and allows users to navigate through the Web, by using a computer mouse to click on “links” that go to other web pages.

What is a border line

Answers

Answer:

a border line is what separates to places from one another like if i were to go to mexico i would have to cross the border

Explanation:

Depends on context.

- Could be a line marking a border

- Barely acceptable; borderline

Example:

She was a borderline candidate.  

This means that she barely made it as a candidate role.

If you are interested in an occupation as an operating system administrator or software engineer, you also may benefit from certifications in networking, hardware, and the Internet. Group of answer choices True False

Answers

True

Explanation:

because in that field there are many things you need to learn and that includes mostly all of them, as an Operating system administrator you most likely need to know things revolving around the system such as the compatibility with the Hardware. And as an Software engineer you NEED to know if your software is even compatible with the new technologys or if there are any problems, the same goes to networking

feel free to correct me

A database provides the capability of conducting searches or asking questions. A question or search for information in a database is called a ________.

Answers

A database provides the capability of conducting searches or asking questions. A question or search for information in a database is called a ___

✓ query

Digital publishing software has increased the use of which of the following?
O paper
O fonts
O color
O photos

Answers

Answer:

~Senpi Boi here~

Explanation:

What the Digital publishing increased was the Photo option.

(Hope this helps!)

Today, the Digital publishing software has increased the use of photos.

What is a Digital publishing software?

This is a software tools that make it easy to publish text and graphic editions in a digital form on electronic devices such as computer, tablet, smartphone etc.

In current time, these software tools has increased the use of photos for publishing.

Therefore, the Option D is correct.

Read more about publishing software

brainly.com/question/26695020

#SPJ2

You have purchased a new LED monitor for your computer. On the back of the monitor, you see the following port (pictured below). Which type of cable should you use to connect the monitor to your computer

Answers

There's no picture however the cable might be a HDMI since it's commonly used
Other Questions
Please help me with this chemistry The interest rate applied to the net lease receivable is the rate that amortizes the gross lease receivable to zero at the end of the lease term. the rate that amortizes the net lease receivable to zero at the end of the lease term. the implicit interest rate. the incremental borrowing rate. What is the net result of one glucose molecule going through the krebs cycle. pls help me no links Triangle ABC is transformed to form triangle ABC.A is at (3, 1), B is at (1, 8), and C is at (7, 2).Which transformation happened to ABC to form ABC?Drag and drop the the correct answers into each box to complete the sentence. ABC____, _____ is Response area Response area to form ABC .Options:1. Rotated Clockwise2. Translated3. Dilated4. Reflected5. 90 about the origin6. 180 about the origin7. 270 about the origin8. across the x-axis9. across the y-axis10. across the line y = x11. 1 unit right 2 units down12. 2 units right 1 unit down13. 4 units left 3 units up14. by a factor of 215. by a factor of 316. by a factor of 5 Climate refugees have migrated into areas already inhabited by people with different cultures, religions, and traditions, increasing the potential for conflict. stronger storms in the pacific and atlantic have threatened whole cities. millions have been displaced by massive flooding in south asia, mexico, and 18 countries in africa. as temperature extremes have increased, tens of thousands have lost their lives. we are recklessly burning and clearing our forests and driving more and more species into extinction. the very web of life on which we depend is being ripped and frayed. which evidence does gore use to support the idea that climate change is occurring? PLS HELP ILL MARK U BRAINLIST What did the guano islands act allow the untied states Given the following: f(x) = 3x - 7; g(x) = 13- 2x; and h(x) = 6xh(g(g(x))) equals 13 - 9.TrueFalse This type of membrane protein enables cells to catalyse specific chemical reactions at the inner or outer surface of their plasma membrane. A biologist sequences the DNA of two different organisms and identifies these two sequences:Sequence 1: GTACCACATCGAAGGGTCSequence 2: GTACGACACCGAAAGTTCWhat conclusion can the biologist draw about the two organisms based on the DNA fingerprinting? A.They are closely related but different species. B.They are the same species. C. One organism evolved from the other. D. They are not related at all. If a polynomial function f(x) has roots 9 and 7 i, what must be a factor of f(x)? (x (7 i)) (x (7 i)) (x (7 i)) (x (7 i)) Surface weather mapPlease help What comes next in this pattern? 7/2, 6/3, 5/4, ... 4/9 4/7 4/5 George is working on a math assignment. He needs to identify which point on the coordinate plane below is located at (7,5). Help George locate the correct point by sharing what you know about the coordinate plane. What is the mass of NaCl required to make 160 grams of a 12% solution of NaCl in water?18 grams19 grams22 grams24 grams Can you please help answer will make you brainliest Which idea does the speaker emphasize by using problem/solution in this passage?The United States does not have room for any more landfills.Landfills are dangerous to the environment.People in the United States throw away too much garbage every day.Efforts should be made to avoid using landfills. 11. why should people consider personal fulfillment as a potential career goal? (20 point) a.it makes job security the most important part of a person's career. b.it shows the importance of advancement within a career path c.it allows financial gain to become a top priority in a career search d.it ensures that a person's values and beliefs have been considered. laura will wear a pair of mittens, a scarf, and a jacket as she leaves the house. she has two pairs of mittens to choose from, six scarves choose from, and three jackets to choose from. how many different combinations laura wear. I WILL GIVE BRAINLESTTTTRJFCFIIEJFJEFLJ