|
-
Vending Machine Program Help!!
Okay I need a little help with this problem
Allow the customer to select a grid location (such as C5). Allow for both upper and lower case input (i.e. C5 and c5 are both valid). Continue to accept input until the user enters two zeroes ("00").
While you may not assume valid user input, you may assume that input will be limited to two characters.
If the input is reversed, such as 5C, output a message as shown in the example and process the input as if it was in the correct order (i.e., C5).
If either the letter or the number of the input is out of range, output an error message as shown in the example.
If the grid location is empty, output an error message as shown in the example.
If the user enters two upper-case O's (OO) instead of two zeroes (00), terminate the program as if the input was two zeroes. Input of two lower-case o's (oo) is invalid.
Now I have most of this done I have the fail condition a two dimensional array the problem that I am running into is I have my two variables set to "char" and in order to process the information through my arrays it has to be in numerical form. I have tried "atoi" but being as they are variables and not constants it won't let me convert them to a number
Similar Threads
-
By arun_pvp2002 in forum Java
Replies: 3
Last Post: 03-06-2008, 07:57 AM
-
By sedricbenson@ho in forum C++
Replies: 2
Last Post: 11-07-2006, 07:58 AM
-
Replies: 0
Last Post: 12-15-2000, 10:07 PM
-
Replies: 2
Last Post: 04-14-2000, 07:39 PM
-
By Matthew Solnit in forum authorevents.appleman
Replies: 1
Last Post: 04-11-2000, 04:39 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks