Verified Document

Pseudocode And Visual Basic Programming

Related Topics:

Visual Basic Programming and Pseudocode Objective of this project is to develop the following applications:

Calculating sales tax on a sale

Converting from Fahrenheit to Celsius

Calculate a total bulk sales using number of units and price per units.

Calculating sales tax on a sale

This paper presents an application to calculate a sale tax. The sale tax rate is 6.48% based on the current rate in the United States.

Pseudocode

Output: Sales tax

Input: annual sale

Percentage of tax

Algorithms

enter the annual sales enter the sales tax rate

Calculate sale tax by multiplying total sales by tax rate (sale *6.48%)

Display sale tax on a sale

Program Interface

Code

Public Class Form1

Private Sub-Label1_Click (sender As Object, e As EventArgs) Handles Label1.Click

' calculate sale tax of a sale ' assign variable

Dim intSale As Integer

Dim intTax As Integer

' assign input to variables

Integer.TryParse (txtSale.Text, intSale)

Integer.TryParse (txtTax.Text, intTax)

'display tax rate

Const dbTax As Double = 0.0648

' calculate sale tax intTax = intTax * interSale

End Sub

Converting Fahrenheit to Celsius

This section develops an application that converts Fahrenheit to Celsius. The formula used to convert Fahrenheit to Celsius is:

Celsius= (Fahrenheit-30)/2

Algorithms

Output: Celsius

Input: Fahrenheit

enter the temperature in Fahrenheit
2. enter the conversion formula

3. Convert Fahrenheit to Celsius by using this formula Celsius= (Fahrenheit=30)/2

4. Display Celsius

Program Interface

Code

Public Class Form1

Private Sub-Label1_Click (sender As Object, e As EventArgs) Handles Label1.Click

' convert Fahrenheit to Celsius

' declare variables

Dim intFahrenheit As Integer

Dim intCelsius As Integer

'assign input to variables

Integer.TryParse (txtFahrenheit.Text, intFahrenheit)

Integer.TryParse (txtCelsius.Text, intCelsius)

' Convert

intCelsius = (Fahrenheit - 30) / 2

End Sub

Total bulk sale price using Number of Units and Price Per Unit

This application calculates the total bulk sales using number of units and price per units. All the sales prices are displayed in dollars.

Algorithm

Output: Bulk Sale Price

Input: Price Per Unit

Number of Units

Algorithms

1. enter the number of units

2. enter the price per unit

3. Calculate the bulk sale price by multiplying the number of units by price per unit

4. Display result

Program Interface

Code

Public Class Form1

Private Sub-TextBox4_TextChanged (sender As Object, e As EventArgs) Handles TextBox4.TextChanged

' calculation of bulk sale price ' assign variable

Dim intUnit As…

Cite this Document:
Copy Bibliography Citation

Related Documents

Visual Basic Programming and Algorithm
Words: 931 Length: 3 Document Type:

Algorithm and Visual Basic Programming Jerry Feingold is the owners of a small restaurant who intends to develop a program that will assist him calculating the total amount used to tip a waiter at the restaurant. The program is designed to deduct any liquor charge from the overall total bill, followed by calculating the tip by using a percentage of the remainder. Finally, the program should be designed to display the

Sign Up for Unlimited Study Help

Our semester plans gives you unlimited, unrestricted access to our entire library of resources —writing tools, guides, example essays, tutorials, class notes, and more.

Get Started Now