# C++ programming

write a program C++ program and Use a recursive function that finds the n-th term using the following rule: tn=3tn-1+12tn-2 .

1. 👍 0
2. 👎 0
3. 👁 425
1. write a program using DO WHILE LOOP

1. 👍 0
2. 👎 0
2. Write a program that computes the cost of a long distance call. The cost of the call is determined
according to the following rate schedules.

a. A call made between 8:00 AM and 6:00 PM is billed at a rate of 6 rupees per minute.
b. A call made before 8:00 AM or after 6:00 PM is charged at a rate of 3.75 rupees.
According to this schedule, if a call starts at any time between 8:00 AM and 6:00 PM, and it ends
after 6:00 PM then it will be charged at the rate of 6 rupees per minute for the time before 6:00
PM and for the rest of the time the rate will be 3.75 rupees per minute. For example if a call
starts at 5:55 PM and ends at 6:05 PM then the charges on this call will be 48.75 (30 rupees for
first 5 minutes and 18.75 rupees for rest of the time).

Similarly if a call starts at the time before 8:00 AM but ends after 8:00 AM then it will be
charged at the rate of 3.75 rupees for the time before 8:00 AM and for remaining minutes after

8:00 AM the rate will be 6 rupees per minute. For example if a call starts at 7:49 AM and ends at
8:01 AM the charge on that call will be 47.25 rupees (41.25 for first 11 minutes and 6 rupees for
last minute).
The input to the program will consist of the time the call started, and the length of call in
minutes. The output will be the cost of call. The time is to be input in 24-hours notation, so the
time 1:30 PM is input as 13:30. The time will be input using two variables of type int, one used
for hour and other used for minutes. The number of the minutes for length of the call will also be
input as a value of type int.

After completing the program test it for following inputs. (first try to judge the answers manually
and then compare the values with the program output. I may be applying different test data to

Input
Output
Start time
Length
Cost
8: 21 10 60
17:55 10
7:49 12
6:00 30
8:00 5

1. 👍 0
2. 👎 0
3. APPLIED PROGRAMMING (APR520S) ASSIGNMENT 1

Problem Solving Tools Total Marks: 50 Marks Due: Friday 22 August 2014

Suppose we want to construct a C/C++ program that can be used to calculate the area or the volume for a range of 2-D and 3-D shapes respectively. Consider only the following shapes.
(a) 2-dimensional shapes: triangle, square, rectangle, circle, and trapezium

(b) 3-dimensional shapes: cuboid, cylinder, cone, and sphere

Suppose that we want our program to firstly ask the user whether to calculate the area (2-D) or volume (3-D), then secondly ask for the type of the shape, then thirdly ask for inputs of all required dimensions, then fourthly calculate the required area or volume, and then finally display the required result to the user.

Required:

1. Construct a flowchart for this C/C++ program. 
2. Develop a pseudocode for this C/C++ program. 
3. Construct a hierarchy (structure) chart for this C/C++ program. 
4. Construct an IPO chart for this C/C++ program. 

1. 👍 0
2. 👎 0

## Similar Questions

1. ### Pseudocode

Write pseudocode for a program that calculates a customer’s total price after tax. The program will ask the user for the price of the item they are buying. Then the program will add a 5% tax to the item and output the final

2. ### Programming concepts

Develop a menu-driven program that inputs two numbers and, at the user’s option, finds their sum, difference, product, or quotient. top-down modular approach and pseudocode to design a suitable program to solve it. I am having

3. ### C++

// Program: name of program // Author: your name // Date Written: date you began writing the program /* Abstract: Brief description of the program */ Include in-line comments in the body of your program. You can convert

4. ### c programming

a student designed a program to accept the age of an employee and then compute the employees retirement year and display the same in a statement on the screen required. a) write out the pseudo-code for the program above b) write

1. ### Algebra

Write a recursive formula for the sequence 5, 18, 31, 44, 57, ... Then find the next term. I’m thinking that the answer is A. A. a1=-8; an=an-1+13. The next term is 70 B. a1=5; an=an-1+13. The next term is 70 C. a1=5;

2. ### Computer Programing & Logic Design

Submit pseudocode and a flowchart for the following programming exercise: Test Average and Grade Write a program that asks the user to enter five test scores. The program should display a letter grade for each score and the

3. ### Pre-Algebra

A survey about the student government program at a school finds the following results: 190 students like the program 135 students think the program is unnecessary 220 students plan on running for student government next year. If a

4. ### CIS

Draw a flowchart or write pseudocode to represent the logic of a program that allows the user to enter a value. The program multiplies the value by 10 and outputs the result.

1. ### Math Plz help

survey about the student government program at a school finds that of 245 students: 218 students like the program 27 students think the program is unnecessary If a circle graph were made from this data, what would the measure of

2. ### statistics

the average number of years a person takes to complete a graduate degree program is 3. the standard deviation is 4 months. Assume the variable is normally distributed. If an individual enrolls in the program, find the probability

3. ### c++

Write a program that asks the user to input a grade that he or she received on an exam. The grade is an integer from 0 to 100 inclusive. The program should convert the numeric grade into the equivalent letter grade. Do the

4. ### Programming

Write pseudocode to represent the logic of a program that allows the user to enter a value for hours worked in a day. The program calculates the hours worked in a five day week and the hours worked in a 252 day work year. The