C# VISUAL BASIC
Manny Management Consulting charges P2,000 for training fee
and P150 per person for registration fee. Create an application
to help the accountant make a billing statement showing the
customer's name, address, number of participants, training fee,
registration fee and total amount due.
Module Module1
Sub Main()
Dim names(100) As String
Dim addresses(100) As String
Dim trainingFee(100) As Double
Dim registrationFee(100) As Double
Dim amountDues(100) As Double
Dim totalAmountDue As Double = 0
Console.Write("Enter the number of participants: ")
Dim numberParticipants As Integer = Integer.Parse(Console.ReadLine())
For i As Integer = 0 To numberParticipants - 1
Console.Write("Enter customer's name: ")
names(i) = Console.ReadLine()
Console.Write("Enter customer's address: ")
addresses(i) = Console.ReadLine()
trainingFee(i) = 2000
registrationFee(i) = 150
amountDues(i) = trainingFee(i) + registrationFee(i)
Console.WriteLine()
Next
Console.WriteLine()
For i As Integer = 0 To numberParticipants - 1
Console.WriteLine("Customer's name: " + names(i))
Console.WriteLine("Customer's address: " + addresses(i))
Console.WriteLine("Customer's training fee: P" + trainingFee(i).ToString())
Console.WriteLine("Customer's registration fee: P" + registrationFee(i).ToString())
Console.WriteLine("Customer's total amount due: P" + amountDues(i).ToString())
totalAmountDue += amountDues(i)
Console.WriteLine()
Next
Console.WriteLine("The total amount due: P" + totalAmountDue.ToString())
Console.ReadLine()
End Sub
End Module
Comments
Leave a comment