![]() |
|
#11
|
||||
|
||||
|
Hi Dewil. I am going to give you an outline of how I would write this program, but you will need to put it together. It appears that you are fairly new to C, but you should know enough to get this going. If not, start looking through your reference book.
I would make a seperate function that would take a char and compare it to your valid list. I would call it, is_valid and have it return a 1 if it is valid and a 0 if it is not. That way I could use it in my main loop like: CPP / C++ / C Code:
Parsing a string in C is very easy, because of the null termination, I would use a char* to parse it until it becomes NULL. CPP / C++ / C Code:
This should get you started. |
||||
Recent GIDBlog
Once again, no time for hobbies by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| some Great site for programming issues | priyanka | Web Design Forum | 8 | 19-Dec-2005 09:55 |
| C programming help!!! | sanman10535 | C Programming Language | 4 | 27-Feb-2004 17:53 |
| question of practice | magiccreative | C++ Forum | 1 | 06-Feb-2004 08:17 |
| Web and Flash design. PHP, MySQL, ASP, JSP programming. | artem | Web Design Forum | 4 | 28-Apr-2002 05:36 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The