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
blagie [28]
3 years ago
15

Write a C# program named ProjectedRaises that includes a named constant representing next year’s anticipated 4 percent raise for

each employee in a company. Also declare variables to represent the current salaries for three employees. Assign values to the variables, and display, with explanatory text, next year’s salary for each employee. Note: For final submission assign the following current salaries for the employees: 25000 for employee 1, 38000 for employee 2, 51000 for employee 3. Then next year's salary for employee 1 would be displayed as: Next year's salary for the first employee will be $26,000.00
Computers and Technology
1 answer:
nydimaria [60]3 years ago
7 0

Answer:

using System;

class ProjectedRaises {

 static void Main() {

     const float raise = 0.04f;

     double salary1 = 0.0f,salary2 = 0.0f,salary3 = 0.0f;

Console.WriteLine("Current salary for each employee: ");

     salary1 = Single.Parse(Console.ReadLine());

     salary2 = Single.Parse(Console.ReadLine());

     salary3 = Single.Parse(Console.ReadLine());

     salary1 = salary1 + raise * salary1;

     salary2 = salary2 + raise * salary2;

     salary3 = salary3 + raise * salary3;

     Console.WriteLine("Next year salary for the employees are: ");

     Console.WriteLine(Math.Round(salary1));

     Console.WriteLine(Math.Round(salary2));

     Console.WriteLine(Math.Round(salary3));

}

}

Explanation:

This declares and initializes variable raise as a float constant

     const float raise = 0.04f;

This declares the salary of each employee as double

     double salary1 = 0.0f,salary2 = 0.0f,salary3 = 0.0f;

This prompts the user for the salaries of the employee

Console.WriteLine("Current salary for each employee: ");

The next three lines get the salary of the employees

<em>      salary1 = Single.Parse(Console.ReadLine());</em>

<em>      salary2 = Single.Parse(Console.ReadLine()); </em>

<em>      salary3 = Single.Parse(Console.ReadLine()); </em>

The next three lines calculate the new salaries of the employees

<em>      salary1 = salary1 + raise * salary1;</em>

<em>      salary2 = salary2 + raise * salary2;</em>

<em>      salary3 = salary3 + raise * salary3;</em>

This prints the header

     Console.WriteLine("Next year salary for the employees are: ");

The next three lines print the new salaries of the employees

     Console.WriteLine(Math.Round(salary1));

     Console.WriteLine(Math.Round(salary2));

     Console.WriteLine(Math.Round(salary3));

You might be interested in
List the different generation of computers with its main component​
Dennis_Churaev [7]

Answer:

1940 – 1956:  First Generation

1956 – 1963: Second Generation

1964 – 1971: Third Generation

1972 – 2010: Fourth Generation

2010-  : (Present )Fifth Generation

Explanation:

  1. First Generation Computers (1940-1956):In this Generation the main component of computers were Vacuum Tubes.
  2. Second Generation Computers (1956-1963):In this generation the main component of computers were Transistors.
  3. Third Generation Computers (1964-1971):In this generation the main component of computers were Integrated Circuits.
  4. Fourth Generation Computers (1972-2010):In this generation the main component of computers were Microprocessor
  5. Fifth Generation (2010-Present):In this generation the main component of computers is Artificial Intelligence
4 0
3 years ago
Game Design Help please
vova2212 [387]

Because, to put it simply, to use more complicated shapes requires more processing power which is unnecessary. Only if they would touch all parts of the shape should it be complicated.

5 0
3 years ago
What query class will you choose<br> for this query "women are evil"?
nikklg [1K]

Answer:

A) Gibberish or Vague Profane

Explanation:

Hope this helps

7 0
2 years ago
The term, botnet, means _____________. a. a program that performs a repetitive task on a network b. spam sent via email to sprea
marshall27 [118]

Answer:

c. a group of compromised computers connected to a network that attacks other networks

Explanation:

<em>Botnets </em>refer to a group of computers controlled from a single source in which software programs are run. Botnets can be used for several purposes, such as scientific (SETI), or computing corporate purposes; on the other hand, botnets are also used for illegal purposes, for instance hacker run malicious programs in order to attack other networks.

4 0
4 years ago
Hazel has just finished adding pictures to her holiday newsletter. She decides to crop an image. What is cropping an image?
NeTakaya
Cropping an image is resizing it to different ratios to suit your needs.

4 0
3 years ago
Other questions:
  • Pointers with classes a) A user-defined class named Timer has a constructor that takes two integer parameters to initialize hour
    14·1 answer
  • What is a digital certificate? Select one: a. It is a means of establishing the validity of an offer from a person, entity, web
    7·1 answer
  • Which of the following features of a network connection between a switch and server is not improved by link aggregation?
    11·1 answer
  • Which of the following describes cloud computing?​
    10·1 answer
  • Raj’s computer just crashed and he lost most of his files. What should he do to avoid this problem in the future?
    10·2 answers
  • python Consider this data sequence: "3 11 5 5 5 2 4 6 6 7 3 -8". Any value that is the same as the immediately preceding value i
    7·1 answer
  • CHEMISTRY. metal+water》base+...............​
    12·1 answer
  • What is the best way to get the most out of the box?
    14·2 answers
  • 1) State one change you could make to a CPU to make a computer work faster.
    10·1 answer
  • if you are using an administrator account during a software installation and you get prompted by the uac, you should
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!