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
Mumz [18]
3 years ago
14

Print Job Cost Calculator (10 points)

Computers and Technology
1 answer:
Ad libitum [116K]3 years ago
8 0

Answer: Provided in the explanation section

Explanation:

Provided is the code  to run this program

Source Code:

import java.util.Scanner;

class PrintJobCost

{

  public static void main(String[] args) {

      Scanner input=new Scanner(System.in);

      System.out.print("Enter print job info:");

      String info=input.nextLine();

      String size="",type="";

      int count=0,i=0,len=info.length();

      double cost=0.0;

      while(info.charAt(i)!=' '){

          size=size+info.charAt(i);  

          i++;

      }

      i++;

      while(info.charAt(i)!=' '){

          type=type+info.charAt(i);

          i++;

      }

      i++;

      while(i<len){

          count=count*10+Integer.parseInt(String.valueOf(info.charAt(i)));

          i++;

      }

      if(size.equals("Letter"))

          cost=cost+0.05;

      else if(size.equals("Legal"))

          cost=cost+0.06;

      else if(size.equals("A4"))

          cost=cost+0.055;

      else if(size.equals("A5"))

          cost=cost+0.04;

      if(type.equals("Grayscale"))

          cost=cost+0.01;

      else if(type.equals("Colored"))

          cost=cost+0.10;

      cost=cost*count;

      System.out.printf("print job Cost:$ %.2f\n",cost);

  }

}

cheers i hope this helped !!!

You might be interested in
COMO HA SIDO LA INNOVACION DE ESTE OBJETO TECNOLOGICO DURANTE SU EVOLUCIÓN
Marizza181 [45]

Answer:

Cual es el objeto tecnologico?

Explanation:

Si dices Cual,puede ser que te ayude.

3 0
3 years ago
If you use a surrogate key, you must ensure that the candidate key of the entity in question performs properly through the use o
Colt1911 [192]
Hello  <span>Abigailguzman6347</span><span>


</span>Answer: If you use a surrogate key, you must ensure that the candidate key of the entity in question performs properly through the use of "unique index" and "not null" constraints.

Hope This Helps!
-Chris
6 0
3 years ago
An optimal solution to a linear programming problem MUST lie A. somewere on the line between two corner points. B. somewhere out
g100num [7]

Answer:

D. at the intersection of at least two constraints.

Explanation:

Linear programming is an optimization technique which is fine for the purpose of getting the best solution such as maximizing profit or certain o 4th era quantities. It is fine by modelling real life problems into mathematical models that have linear relationships or constraints such as in the form of objective functions. In linear programming, an objective function defines the formula for quantity optimization and the goal from this is to determine variable values that maximize or minimize the objective function depending on the problem robbery solved.

8 0
3 years ago
What is the typical relationship between time and interest rate?
prisoha [69]
The relationship between time and interest is: time allowed to repay the loan (monthly payments)
7 0
2 years ago
What is a method whereby new problems are solved based on the solutions from similar cases solved in the past?
mario62 [17]

Answer:

"Case-Based Reasoning" is the answer for the above question.

Explanation:

  • Case-Based Reasoning is a process of decision-making theory in which the new problems were solved based on the previously solved problem.
  • It is used in artificial intelligence and robots. This helps to make any AI and robots to do the work and take decisions on its own.
  • The theory is used to make any computer that behaves like humans. It can take decisions like a human.
  • The above question asked about the method by which the new problem is solved on behalf of the old problem. Hence the answer is "Case-Based Reasoning".
4 0
3 years ago
Other questions:
  • What is the primary purpose for a screen saver in windows?
    8·1 answer
  • "where is a cookie that is created during a web site visit​ stored?"
    9·1 answer
  • Which word processing file that contains text and other
    13·2 answers
  • Advertising is organized around four distinct groups. The _____ group includes the photographers, the illustrators, video produc
    9·1 answer
  • Which type of CPU instruction performs arithmetic calculations and stores the results in memory?
    14·2 answers
  • Graphic software task​
    7·1 answer
  • Excel files have a default extension of ?
    12·1 answer
  • Mention any
    14·1 answer
  • Noah is creating a startup. He uses the website Upwork to hire freelancers in India and in the Ukraine to work for him. This is
    8·1 answer
  • Q2: Mark True or False in the corresponding Answer sheet (0.5 point each)
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!