Create visual logic flow chart from the following pseudocode

Assignment Help Database Management System
Reference no: EM13945507

Create visual logic flow chart from the following pseudocode.

Begin Program:

//Initialize program variables
Initialize Regular_Price = 3.00;
Initialize Premium_Price = 3.20;
Initialize Fed_Gas_Tax_Regular_Rate = .10;
Initialize Fed_Gas_Tax_Premium_Rate = .10;
Initialize Gas_n_Go_Charge = 1.00;
Initialize Full_Service_Charge = 2.00;
Initialize State_Sales_Tax_Rate = .05;
Initialize Gallons;
Initialize State_Sales_Tax;
Initialize Fed_Gas_Tax;
Initialize Gas_Choice;
Initialize Gas_Cost;
Initialize Service_Type;
Initialize Extra_Charge;
Initialize Total_Cost;

//User to input the type of gas loaded.
Display "Enter Type of Gas: Regular or Premium. ";
Input Gas_Choice;

//User to input the amount of gas loaded
Display "Enter amount of gallons: ";
Input Gallons;

//User to input the type of service offered to the customer
Display "Enter type of service rendered: Gas-n-Go, Full-Service, None. ";
Input Service_Type;

//Gas cost and federal gas tax for Regular
If (Gas_Choice == "Regular")
{
Gas_Cost = Gallons * Regular_Price;
Fed_Gas_Tax = Gallons * Fed_Gas_Tax_Regular_Rate;
}
//Gas cost and federal gas tax for Premium
Else if (Gas_Choice = "Premium")
{
Gas_Cost = Gallons * Premium_Price;
Fed_Gas_Tax = Gallons * Fed_Gas_Tax_Premium_Rate;
}

//Extra charge for Gas nâ?? Go
If (Service_Type == "Gas-n-Go")
Extra_Charge = Gas_n_Go_Charge;
//Extra charge for Full Service
Else if (Service_Type == "Full-Service")
Extra_Charge = Full_Service_Charge;
//No extra charge if no extra service was given
Else if (Service_Type == "None")
Extra_Charge = 0;

// State Sales Tax
State_Sales_Tax = State_Sales_Tax_Rate * (Gas_Cost + Extra_Charge);

// Total Cost to be billed to the customer
Total_Cost = Gas_Cost + Extra_Charge + State_Sales_Tax + Fed_Gas_Tax;

//Display of Cost
Display "Total Gas Cost: ";
Display Gas_Cost;
Display "Service Charge: ";
Display Extra_Charge;
Display "Federal Gas Tax: ";
Display Fed_Gas_Tax;
Display "State Sales Tax: ";
Display State_Sales_Tax;
Display "Total Amount: ";
Display Total_Cost;

End Program:

Reference no: EM13945507

Questions Cloud

Write assembly language program for the marie processor : Please refer to the attachment for the general structure of the assembly language source code and more specifications regarding the assembly program
What fifth reason has been added recently : One aspect of sustainability is ecological restoration. What is ecological restoration and how is it important to ecosystems? What are four traditional reasons for the development of parks and protected areas?
Calculate hunter''s rate of return on total assets : Use the DuPont system to calculate the return on assets for the two years, and determine why they changed.
Purpose of commodore perry mission : Which of the following diseases was virtually eradicated through inoculation? The purpose of Commodore Perry's mission to Japan in 1853 was to
Create visual logic flow chart from the following pseudocode : Create visual logic flow chart from the following pseudocode.
How would the federal air marshal service : How would the federal air marshal service respond to a global security situation when compared to United States federal services? What are some examples of the similarities and the differences in their responses? Why do these similarities and differe..
What are the consequences of my reasoning : State whether you believe that the public, in the form of government, has the right to impose restrictions on individual landowners. State the reasons for your beliefs and directly answer the following critical thinking questions after stating you..
Design a grade average program that will produce the numeric : Design a grade average program that will produce the numerical grade average of test scores input by a user.
Evaluate your selected criminal justice policy : Select a policy from the list of examples found in Chapter 1 of Criminal Justice Policy in Table 1.1 "Examples of Federal Criminal Justice Policies" (Mallicoat, 2014). In this discussion, you will evaluate your selected criminal justice policy by ..

Reviews

Write a Review

Database Management System Questions & Answers

  Convert the erd

Using the descriptions of the attributes given in the, convert the ERD shown in Figure P6.2 into a dependency diagram that is in 3NF.

  Give an example of a view on emp that would be impossible to

Give an example of a view on Emp that would be impossible to update (auto- atically) and explain why your example presents theupdate problem that it does.

  Produce an entity-relationship model for the scenario

Produce an Entity-Relationship Model for the scenario, Query your database, Optimize your Database,Secure your Database, and built Building a Web Interface

  Explore ways of converting depositors to borrowers

Universal Bank is a young bank growing rapidly in overall customer acquisition. The majority of these customers are depositors with varying sizes of relationship with the bank. The customer base of borrowers is quite small, and the bank is interes..

  Create appropriate primary and foreign key constraints

Take a look at the query specifications in question 3. You will need to have data values that are relevant to these queries. BUT the design of your tables and test data should not be compromised merely to support just these queries.

  What is the most common database query language

What is the most common database query language? What is the name for a column that uniquely identifies a record

  What is a data warehouse and why is rei building one

What is a data warehouse and why is REI building one and What are some of the risks or concerns surrounding the creation of a data warehouse

  Write a memorandum to sam jones

Write a memorandum to Sam Jones (CIO) and present your research findings. Your memorandum should be no longer than 500 words.

  Construct relational database for new yorks fire department

The state wants to record fire department for which each fire fighter currently works and each fire fighter's supervisor. Supervisors are always higher-ranking certified fire fighters - Construct relational database for New York's fire departments..

  Vehiclerentaloz data warehousevehiclerentaloz is a large

vehiclerentaloz data warehousevehiclerentaloz is a large chain of vehicle rental company over 500 stores distributed

  What is the goal of computer forensics

From your knowledge and experience how are computer forensic investigators, in today's world of complex technology, are able to retrieve and analyze data that can be used in computer forensic investigations.

  Execution of the SQL commands - Create Tables using SQL DDL

The appropriate SQL command which should be copied from your source code in MySQL and resultant tables, which must be screenshots to show the change due to the execution of the SQL commands

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd