Write a program that computes the cost of a long distance call. The cost of the call is determined according to .
• A call made between 8 AM and 6 PM is at a rate of 6 rupees per minute.
• A call made before 8 AM or after 6 PM is charged at a rate of 3.75 rupees.
if 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 min for the time before 6:00 PM and for rest of time the rate will be 3.75 rupees per min For example if call starts at 5:55 PM and ends at 6:05 PM then charges on this call be 48.75(30 rupees for first 5 mins and 18.75 rupees for rest of the time) if a call starts at time before 8:00 AM but ends after 8:00 AM then it will charged at rate of 3.75 rupees for time before 8:00 AM and for remaining minutes after 8:00 AM the rate will 6 rupees per min. 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 min and 6 rupees for last min).
(use two-dimensional array)A company has four salespeople (1-4) who sell five different products (1-5).each salesperson passes in a slip for each different type of product sold. Each slip contains the following:
a) salesperson number
b) product number
c) total dollar value of that product sold that day
Thus, each salesperson passes in between 0 and 5 sales slips per day. Assume the information from the slips for last month is available. Write a program that will read all information for last month’s sales (one salesperson’s data at a time) and summarize the total sales by salesperson by product. All totals should be stored in the two-dimensional array sales. After processing all the information for last month, print the results in tabular format with each of the columns representing a salesperson and each of the rows representing a product. Cross total each row to get the total sales of each product for last month; each column to get the total sales by salesperson for last month.
Write a program that first print the student’s marks data given in the attached excel file then show the
horizontal bar chart of the grades frequency which student achieved and in the last tell us which grade
category got maximum and minimum number of students.
You are given an array of N non-negative integers: A1, A2, ..., AN. An alternating subsequence is a subsequence in which the indices of any two consecutive elements differ by exactly two in the original array. That is, if Ai1, Ai2, ..., Aik is some subsequence, then for it to be an alternating subsequence, (i2 - i1 = 2), (i3 - i2 = 2), and so on should all hold true. Among all alternating subsequences, find the one which has maximum sum of elements, and output that sum.
The first line of the input contains an integer T denoting the number of test cases.
The first line of each test case contains an integer N denoting the number of elements in the array.
The second line contains N space-separated integers A1, A2, ..., AN denoting the array A.
For each test case, output a single line containing the answer.
Note
A subsequence with only a single integer is also an alternating subsequence.
Create a Student class, where attributes associated with each student are name, registration
number, father name, degree and department. All attributes should not be accessed directly.
One can view the details of all students. Note student attributes cannot be changed by any
means after initialization. (Hint use constant objects)
Write a program that calculates and prints the monthly paycheck for an employee. The program takes as input
the gross pay and name of the employee from the user. It then calculates the net pay after taking the following
deductions on the gross pay:
Income Tax = 15%
Medicare Tax = 3.5%
Pension Fund = 2.75%
House Rent = 1000 Rs (fixed amount)
T
OUTPUT
sooorrrrrrrrryyyyy
Given Code Editor:
#include <iostream>
using namespace std;
void sendApology(char, int);
int main(void) {
sendApology('s', 2);
sendApology('f', 10);
sendApology('b', 3);
sendApology('o', 5);
sendApology('r', 12);
sendApology('m', 5);
sendApology('v', 2);
sendApology('y', 7);
return 0;
}
void sendApology(char letter, int n) {
// TODO: Implement the function definition
}
Write a program that computes the cost of a long distance call. The cost of call is determined according to the following rate schedules.
• A call made between 8:00 AM and 6:00 PM is billed at a rate of 6 rupees per minute.
• 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 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 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 call starts at the time before 8:00 AM but ends after 8:00 AM then it will be charged at 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.
Using function, write and run a C++ program to computer the root of a quadratic equation,stating the conditions for real,complex and double roots respectively in your program
Using user defined function;write and run C++ program that computes the first 10 terms of an Arithmetic Progression (AP)