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


There are 21 people in a room. They have to form groups of 3
people each. How many combinations are possible? Write a C
program to print the same.



There are 21 people in a room. They have to form groups of 3 people each. How many combinations are..

Answer / jeeva kumar

#include<stdio.h>
#include<conio.h>

void main()
{
clrscr();
int i,n,a,b,c=1,d=1;
printf("Enter the tot no of people");
scanf("%d", &n);
printf("In how many they have to form group");
scanf("%d", &a);
b=a;
for(i=0;i<b;i++)
{
c*=n;
d*=a;
n--;
a--;
}

printf("%d",c/d);
getch();
}

Is This Answer Correct ?    7 Yes 0 No

Post New Answer

More C Interview Questions

write a C and C++ programme to implement the A,bubble sort B,quick sort C,insertion sort D,sequential search E,binary search

1 Answers   ADP, TCS,


in ‘C’ language for Matrix Multiplication fails” Introspect the causes for its failure and write down the possible reasons for its failure.

0 Answers   TCS,


What is a MAC Address?

0 Answers  


Function which gives a pointer to a binary trees const an integer value at each code, return function of all the nodes in binary tree.?

0 Answers   Infosys,


What is a Deque?

2 Answers  


hw can we delete an internal node of binary search tree the internal node has child node..plz write progarm

0 Answers   TCS,


The performance of an operation in several steps with each step using the output of the preceding step a) recursion b) search c) call by value d) call by reference

0 Answers  


why use "return" statement a) on executing the return statement it immediately transfers the control back to the calling program b) it returns the value present in the parentheses return, to the calling program c) a & b d) none of the above

0 Answers  


How can I make a program in c to print 'Hello' without using semicolon in the code?

9 Answers   C DAC, Practical Viva Questions,


main() { char x; while(x=0;x<=255;x++) printf("\nAscii value %d Charater %c",x,x); }

2 Answers  


How pointer is benefit for design a data structure algorithm?

2 Answers  


What is the use of sizeof?

0 Answers  


Categories