75.1k views
0 votes
To define a c-string that will store students' last names of up to 25 characters in length, which is an appropriate statement?

User Tristin
by
6.6k points

1 Answer

5 votes
The answer is : char lastName[26];
This is the appropriate statement to define a C-string that will store students' last names of up to 25 characters in length. C-string is a string whose characters are stored in consecutive memory locations, and are followed by a null character, or null terminator.
User Michael Cohen
by
6.3k points