![]() |
|
#1
|
|||
|
|||
Morse Code for CHi All,
i need to input ("English Letter") and print the output as Morse Code. Rather new to C program. SO i don't know about strings etc... But i do know that it involves char, put char(), print char () and probably even switches. Can someone give me an idea how to begin doing? thanks! |
|||
|
#2
|
||||
|
||||
|
Quote:
Define a character array inbuf for your input of "English Letter". Define a 2 dimensional array for the Morse Code: CPP / C++ / C Code:
The 256 is for each ASCII character. Look up each character's value in an ASCII chart The 10 is for the characters needed for each morse code symbol. Read a sentence into inbuf and look at each character. Use that character as an index into the morse array to output the morse code for the character. __________________
The 3 Laws of the Procrastination Society: 1) Never do today that which can be put off until tomorrow 2) Tomorrow never comes |
Recent GIDBlog
Problems with the Navy (Enlisted) by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Re: Formatting C / C++ code | WaltP | C Programming Language | 1 | 06-Jan-2008 23:59 |
| very difficult code - program | gaurav_sting | C++ Forum | 1 | 16-Jun-2004 00:59 |
| Speed up C++ code about 3d array! | Truong Son | C++ Forum | 0 | 16-Mar-2004 21:52 |
| Explain code in MS STL's binary_search | rom | C++ Forum | 11 | 07-Mar-2004 20:11 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The