Question: Question 1 5 2 pts What does the following function do ? int func ( char * str ) { int c = 0 ;

Question 15
2 pts
What does the following function do?
int func(char *str)
{
int c=0;
while ( str !='??0')
{
c++;
str++;
}
return c;
}
A. It accepts a pointer to a C-string as an argument and returns the number of times '??0' appears in the string.
B. It accepts a pointer to a C-string as an argument and returns a pointer to the null terminator.
C. It accepts a pointer to a C-string as an argument and returns the number of characters in the string, not including the null terminator.
D. It accepts a pointer to a C-string as an argument and returns the number of characters in the string, including the null terminator.
 Question 15 2 pts What does the following function do? int

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!