Using a two-dimensional and one-dimensional array, create a program that will display the cost of a Bahamasair ticket given the FROM and TO locations. The cities/towns to use for this program:Nassau, Freeport, harbour island and marsh harbour
islandgirl242
0
Newbie Poster
Recommended Answers
Jump to PostWe won't do your homework for you, but if you show us what you have tried so far and where you are stuck perhaps we can help.
Jump to PostYou declare the dimensions of island as [4,1] but you index the columns as 0, 1, 2, 3 (lines 2-5). Did you mean to do
island[0, 0] = "Nassau" + "210"; island[1, 0] = "Freeport" + "$350"; island[2, 0] = "HarbourIsland" + "$400"; island[3, 0] = "MarshHarbour" + "$275";
All 5 Replies
Reverend Jim
4,780
Hi, I'm Jim, one of DaniWeb's moderators.
Moderator
Featured Poster
islandgirl242
0
Newbie Poster
Reverend Jim
4,780
Hi, I'm Jim, one of DaniWeb's moderators.
Moderator
Featured Poster
islandgirl242
0
Newbie Poster
Reverend Jim
4,780
Hi, I'm Jim, one of DaniWeb's moderators.
Moderator
Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.