Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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 / rajesh

options A and C are correct....
Check it in C programming online editor www.codepad.org

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is c platform dependent?

1071


State two uses of pointers in C?

1041


How can you restore a redirected standard stream?

1105


A SIMPLE PROGRAM OF GRAPHICS AND THEIR OUTPUT I WANT SEE WAHAT OUTOUT OF GRAPHICS PROGRAM

2110


What is modeling?

1031


Do you know the difference between exit() and _exit() function in c?

1048


What is the meaning of 2d in c?

1104


What are the types of type qualifiers in c?

1070


Why do we need functions in c?

1001


How do I determine whether a character is numeric, alphabetic, and so on?

1115


Explain how can you avoid including a header more than once?

1074


What is the difference between the = symbol and == symbol?

1092


List the difference between a "copy constructor" and a "assignment operator"?

994


What would the following code segment printint k = 8;docout << "k = " << k << " ";while k++ < 5; a) 13 b) 5 c) 8 d) pointers

1241


What is the usage of the pointer in c?

1093