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

If we give two names then this displays the connection
between the two people. It is nothing but flames game

Answer Posted / gita

main()
{
char name1[20],name2[20];
int a,b,i,j,c;
clrscr();
printf("Enter the first name:\t");
gets(name1);
printf("Enter the second name:\t");
gets(name2);
a=strlen(name1);
b=strlen(name2);

for(i=0;i<=a;i++)
{
for(j=0;j<=b;j++)
{
if(name1[i]==name2[j])
{
a--;
b--;
}
}
}
c=a+b;
i=c%6;
switch(i)
{
case 0:printf("Friends");
break;
case 1:printf("lovers");
break;
case 2:printf("Ansisters");
break;
case 3:printf("marriage");
break;
case 4:printf("enemies");
break;
case5:printf("sisters");
break;
}

getch();
}

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What library is sizeof in c?

1088


How can I swap two values without using a temporary?

1104


What is advantage of pointer in c?

1184


What is a stream water?

1211


how to execute a program using if else condition and the output should enter number and the number is odd only...

2296


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

1222


Explain what is the benefit of using an enum rather than a #define constant?

1220


What are the parts of c program?

1101


What is bash c?

1008


write a sorting prgm to sort 50 nos and sum them and also remove all the occurrences of 15 and print it?

2129


Are pointers integers in c?

1073


code for replace tabs with equivalent number of blanks

2160


What is the difference between the = symbol and == symbol?

1114


praagnovation

2278


How can you determine the maximum value that a numeric variable can hold?

1233