Quote:Original post by deadstarQuote:Original post by JavaMava
It's a character array like the second example.
Then you don't 'find out' how many characters it has, you declare it yourself when you create it.
In that example, the array holds 255 characters. Or a more efficient way is to create an integer to keep track:
*** Source Snippet Removed ***
I see where your coming from. I guess I should give out more info about what I'm doing. I need to write a function only (not the main) that accepts a const char checks it for 1 or 0 characters, ignores all others, blah blah blah turns the binary into decimal and prints out what the ASCII characters.
In the assignment description the function should be able to handle any number of characters. I'll have a main to test it out, but the main the professor is going to use to test, wont be telling my function how many characters it's sending it. Simply sending it the const char xxxx[ ] and asking what ascii my function can pull out of it.