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

Struct(s)
{
int a;
long b;
}
Union (u)
{int a;
long b;
}
Print sizeof(s)and sizeof(u) if sizeof(int)=4 and
sizeof(long)=4

Answer Posted / jack

I assume above code to be correctly written as below:
struct s
{
int a;
long b;
}
Union u
{int a;
long b;
}
sizeof(s)= 8
sizeof(u) = 4

Is This Answer Correct ?    9 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can a number be converted to a string?

1242


Write a program to print numbers from 1 to 100 without using loop in c?

1027


Write a program to check palindrome number in c programming?

963


what is the differnce between programing langauge and tool? is sas is a programing langauge r tool?

2307


What is an auto variable in c?

1168


How can I invoke another program or command and trap its output?

1046


Explain goto?

1094


Explain what is the purpose of "extern" keyword in a function declaration?

1029


What is the heap in c?

1030


Which is better pointer or array?

974


Can I initialize unions?

987


What are the usage of pointer in c?

1122


i have to apply for the rbi for the post of officers. i need to know abt the entrance questions whether it may be aps or techinical....

1917


What is the difference between int main and void main?

999


can any one provide me the notes of data structure for ignou cs-62 paper

2118