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

Write any small program that will compile in "C" but not
in "C++"

Answer Posted / karunesh

int GetNum()
{

printf("this will compile under c but not in c++");

}

you will get a error under g++ funtion should return int
while in c i will work with warning.

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you create a virtual copy constructor?

1087


Explain the concept of dynamic allocation of memory?

1100


Is there a sort function in c++?

1001


What are the manipulators in c++?

1041


Can member data be public?

1037


Define a nested class.

1078


What is the use of ::(scope resolution operator)?

1075


How are Structure passing and returning implemented by the compiler?

1139


What are the extraction and insertion operators in c++? Explain with examples.

1195


Is nan a c++?

1152


What is conditions when using boolean operators?

1232


Can a list of string be stored within a two dimensional array?

1000


How do you define/declare constants in c++?

1054


What is the full name of logo?

1124


What is polymorphism in c++? Explain with an example?

1034