program that compares interest rates between two banks, Visual Basic Programming

'This program compares interest rates between two banks and determines the best bank

PublicClassForm1

PrivateSub Button1_Click(sender AsSystem.Object, e AsSystem.EventArgs) Handles Button1.Click

'Declarations

Dim annualInterest1, annualInterest2, annualInterestAPY1, numberCompoundedPeriods1, annualInterestAPY2, numberCompoundedPeriods2 AsDouble

'Input

        annualInterest1 = CDbl(TextBox1.Text)

        annualInterest2 = CDbl(TextBox4.Text)

        numberCompoundedPeriods1 = CDbl(TextBox2.Text)

        numberCompoundedPeriods2 = CDbl(TextBox5.Text)

'Processing

        annualInterestAPY1 = (1 + ((annualInterest1 / 100) / (numberCompoundedPeriods1)) ^ numberCompoundedPeriods1 - 1)

        annualInterestAPY2 = (1 + ((annualInterest2 / 100) / (numberCompoundedPeriods2)) ^ numberCompoundedPeriods2 - 1)

'Output

        TextBox3.Text = CStr(annualInterestAPY1 * 100)

        TextBox6.Text = CStr(annualInterestAPY2 * 100)

EndSub

EndClass

Posted Date: 3/21/2013 5:39:08 AM | Location : United States







Related Discussions:- program that compares interest rates between two banks, Assignment Help, Ask Question on program that compares interest rates between two banks, Get Answer, Expert's Help, program that compares interest rates between two banks Discussions

Write discussion on program that compares interest rates between two banks
Your posts are moderated
Related Questions
The Select Case structure provides an option to If...Then...Else If for selectively executing one block of statements from amongst multiple blocks of statements. Any Select Case st

Restricting The Vocabulary: The properly formed vocabulary is like an inverted pyramid. All easy to learn communication system follow this pattern. The canonical vocabulary in

Assume that s is a string variable that is supposed to contain a value to be converted to integer. Write a fragment of code that converts the value to integer variable and displ


what are the functions and the importance of hierarchy operators

You can employ For...Next statements to run a block of statements a specific number of times. For loops, employ a counter variable whose value is increased or decreased with each r

Properties: Every control has a default property related with it. The default property does not require to be named when you are functioning. The control Check box as value

Numeric data types: The Integer, long integer are used for entire numbers. Single and doubles are related with the floating point numbers. Currency is related with numbers dea

We will discuss scripting language; called VB Script. VBScript is Microsoft's scripting language. It enables us to write programs which enhance the power of Web pages by letting us

Create the flowcharts using MS Visio, MS Excel or MS Word to demonstrate the algorithm. Submit your flowchart under the assignment for CH7-4-26 Flowchart. Part Printouts H