1)what is the error in the following stmt where str is a
char array and the stmt is supposed to traverse through the
whole character string str?

for(i=0;str[i];i++)

a)There is no error.
b)There shud be no ; after the stmt.
c)The cond shud be str[i]!='\0'
d)The cond shud be str[i]!=NULL
e)i shud be initialized to 1

Answer Posted / vinod

Options D,E are correct for this

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you increase the allowable number of simultaneously open files?

587


write a programe to accept any two number and check the following condition using goto state ment.if a>b,print a & find whether it is even or odd and then print.and a

1444


How do you determine a file’s attributes?

589


What is the difference between fread and fwrite function?

629


Do you know null pointer?

596






Give me the code of in-order recursive and non-recursive.

872


What is the ANSI C Standard?

768


Is javascript based on c?

585


Is null valid for pointers to functions?

597


Explain how can type-insensitive macros be created?

564


What are the types of arrays in c?

615


What does dm mean sexually?

803


What are control structures? What are the different types?

587


What is null pointer constant?

588


What are the features of c language?

611