Question
I'm totally lost on this homework question. It's one of my first times constructing actual C# code with correct syntax, and I feel like if
I'm totally lost on this homework question. It's one of my first times constructing actual C# code with correct syntax, and I feel like if I could have an example of how to do this one correctly, I could do the rest of the problems on my homework. I have constructed the IPO chart & algorithm so far..
1) Assume that you've been asked to write an application that determines whether a department store customer has exceeded the credit limit on a charge account. Each customer enters an account number, a beginning balance, the total charged for the month, the total credits for the month and the credit limit. The application should display the new balance. If the credit limit is exceeded, the application should display an appropriate message to the user.
For example, if the user owes $500 at the beginning of the month, charges an additional $100 during the month and makes a $50 payment, their balance at the end of the month is 500 + 100 - 50 or $550.
Start by constructing an IPO chart and an algorithm in pseudocode, then, in dotnetfiddle.net or Visual Studio, translate the algorithm into syntactically correct C# code. Use Main method.
Input:
accountNumber begBalance charges credits creditLimit
Processing:
get accountNumber, begBalance, charges, credits, creditLimit calculate newBalance display newBalance display message when newBalance exceeds creditLimit
Output:
newBalance message
Algorithm:
display instructions get begBalance get credits get charges get creditLimit newBalance = begBalance + charges - credits display newBalance if newBalance > creditLimit display an appropriate message box end if
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started