Programming in GWBASIC

Document Sample
Programming in GWBASIC Powered By Docstoc
					                  Programming in GWBASIC


Assignment 2 (Bubble sort)

Write a program that:

    takes 5 input numbers and stores them in an Array variable
    then sorts the numbers in the array in ascending order
    finally prints the sorted array on screen

e.g. if the following sequence of numbers are entered:

50
99
25
120
80

Your program should return the following output on the screen:

25
50
80
99
120


Your program should prompt user if they want to have another go before
terminating.

Hint: Additional statements, DIM


Provide a report showing the procedure you followed to write the
program. Include your flow diagrams and screen snapshots of the
program runs with two sets of input values.

				
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
views:34
posted:11/7/2012
language:English
pages:1