I have just started a basic class in programming and I am totally lost. Can someone help me out? I have to write pseudocodes and create flowcharts and don't have a clue. I need help.
Create flowcharts and pseudo-code for the following problems:

1. You're trying to figure out where to go on vacation. Here are the different scenarios: First, check how many vacation days you have left. If you have less than 2 days, you will stay at home. If you have between 2 and 4 days, you will go to Asheville. If you have more than 4 days, you check your budget. If your budget is greater than $1200, you will go to Aruba. Otherwise, if it's greater than $800, you will go to Miami. If it's not greater than $800, you will go to Orlando.

2. You need to calculate the discount that your customers receive based on the value of their order. If the total amount ordered is less than $20, no discount will be given. If the total amount is between $20 and $50, a discount of 5% will be given. If the total amount is greater than $50 and less than $100, a discount of 10% will be given. If the total amount is $100 or more, a premium customer receives 20% discount and a regular customer receives 15% discount.

Hi I know pseudo code is not a generic language... I've google about a little and found different / similar words with the same meaning, however I'm a little stuck on the

"toss = 1 + rand() % 2"

Which basically looks at the system clock ,creates a random number between 1 and 2 and stores it at int toss.

All I’ve thought of is this:
Declare variable toss

Create random between 1 and 2

Store number at toss


I’m not convince this is the best way

<< moderator edit: split thread from [thread=15857]here[/thread] >>

11 Years
Discussion Span
Last Post by Dave Sinkula
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.