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...

f(char *p)
{
p=(char *)malloc(sizeof(6));
strcpy(p,"HELLO");
}
main()
{
char *p="BYE";
f(p)
printf("%s",p);
}
what is the output?

Answer Posted / deepa

SOORY FOR POSTIN THE WRONG ANSWER THE ANSER WUD BE BYE COZ
THE *P DIES IN THE FUNCTION ITSELF AS WE ARE NOT RETURNING
THE STRING BACK IN THE MAIN PROGRAM

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is variable declaration and definition in c?

856


Explain a pre-processor and its advantages.

1073


How will you declare an array of three function pointers where each function receives two ints and returns a float?

1292


What are different storage class specifiers in c?

1042


What is queue in c?

1033


Is c is a procedural language?

1033


What are the various types of control structures in programming?

1006


Should I learn data structures in c or python?

976


In this assignment you are asked to write a multithreaded program to find the duplicates in an array of 10 million integers. The integers are between -5000,000 to 5000,000 and are generated randomly. Use 10 threads, each thread works on 1000,000 integers. Compare the time needed to accomplish the task with single thread of execution program. Do not include the time to fill the array with integers in the execution time.

3068


Explain how are 16- and 32-bit numbers stored?

1207


What is the use of pragma in embedded c?

1003


What is the general form of a C program?

978


When should you use a type cast?

1056


What is huge pointer in c?

1022


What is the default value of local and global variables in c?

983