{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

HW2_solution - BIT 3444 Homework 2 Due Thursday October 2...

Info icon This preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
1 BIT 3444 Homework 2 Due Thursday, October 2, 2008 (Before Class) Homework 2 Submission : Save your completed homework as a Microsoft Word document using the following name format: 2_LastName_FirstInitial.doc. Upload the file to our homework submission site. 1. Complete the table by filling in the value of each variable after each line is executed. (5 Points) balance interest withdraw Private Sub EvaluateButton_Click(…) Handles _ EvaluateButtion.Click Dim balance As Double =0D, interest As Double =0D, _ withdraw As Double =0D 0.0 0.0 0.0 balance = 50.0 50.0 0.0 0.0 interest = 0.03 50.0 0.03 0.0 withdraw = 30.0 50.0 0.03 30.0 balance += interest * balance 51.5 0.03 30.0 balance -= withdraw 21.5 0.03 30.0 End Sub 2. Determine the out put displayed when the button is clicked (35 Points in Total, 5 Points Each) (1) Private Sub DisplayButton_Click(...) Handles DisplayButton.Click Dim name, test As String Dim n As String = "" name = "BIT" For i As Integer = 0 To name.Length - 1 test = name.Substring(i, 1) n = test & n Next ResultTextBox.Text = n End Sub “TIB”
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
2 (2) Private Sub DisplayButton_Click(…) Handles DisplayButton.Click Dim num1 As Integer, num2 As Integer Dim word As String = "hello world" num1 = 3 num2 = 9 Select Case (2 * num2 – 2) Case num1 * num1 ResultTextBox.Text = "Less is more."
Image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern