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

#include<stdio.h>
main()
{
char *p1;
char *p2;
p1=(char *) malloc(25);
p2=(char *) malloc(25);
strcpy(p1,"Ramco");
strcpy(p2,"Systems");
strcat(p1,p2);
printf("%s",p1);
}

Tell me the output?

Answer Posted / sumant

the output will be RamcoSystems
but we need 2 more libraries
#include<string.h> and
#include<alloc.h>
to run this program. in else case it will not work.

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Create a simple code fragment that will swap the values of two variables num1 and num2.

1285


What is bss in c?

1099


What should malloc(0) do? Return a null pointer or a pointer to 0 bytes?

1075


Explain how can a program be made to print the name of a source file where an error occurs?

1197


Can you return null in c?

1163


Explain what is #line used for?

1064


What do you mean by dynamic memory allocation in c?

1102


How do I swap bytes?

1069


What is pass by reference in functions?

846


What is function pointer c?

1108


exit () is used to a) exit () terminates the execution of the program itself b) exit () terminates the execution of the loop c) exit () terminates the execution of the block d) none of the above

1115


while loop contains parts a) initialisation, evalution of an expression,increment /decrement b) initialisation, increment/decrement c) condition evalution d) none of the above

1242


How can variables be characterized?

2186


Why do we use static in c?

1125


What is c method?

996