in a town the percentage of men is 52 the percentage of
total literacy is 48 if total percentage of literate men is
35 of the total population write a program to find the
total no of the literate men and women if the population of
the town is 80000

Answer Posted / bhawna

#include<stdio.h>
#include<conio.h>
main()
{
int per_men, tot_men, tot_lit_pop, tot_lit_per, men_lit_per, tot_lit_men, tot_lit_wom, tot_wom, ilt_wom, ilt_men, tot_pop=80000;

per_men=52;
tot_men=tot_pop*per_men/100;
tot_lit_per=48;
tot_lit_pop=tot_pop*tot_lit_per/100;
men_lit_per=35;
tot_lit_men=tot_pop*men_lit_per/100;
tot_lit_wom=tot_lit_pop-tot_lit_men;
tot_wom=tot_pop-tot_men;
ilt_men=tot_men-tot_lit_men;
ilt_wom=tot_wom-tot_lit_wom;


printf("\nTotal Population = %d",tot_pop);
printf("\nTotal number of Men = %d",tot_men);
printf("\nTotal number of Literate Population = %d",tot_lit_pop);
printf("\nTotal number of Literate Men = %d",tot_lit_men);
printf("\nTotal number of Literate Women = %d",tot_lit_wom);
printf("\nTotal number of Women = %d",tot_wom);

printf("\nTotal number of Illiterate Men = %d",ilt_men);
printf("\nTotal number of Illiterate Women = %d",ilt_wom);

getch();
}

Is This Answer Correct ?    8 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is wild pointer in c with example?

570


4-Take two sets of 5 numbers from user in two arrays. Sort array 1 in ascending and array 2 in descending order. Perform sorting by passing array to a function mySort(array, sortingOrder). Then multiply both the arrays returned from function, using metric multiplication technique in main. Print result in metric format.

1723


What oops means?

578


Differentiate between full, complete & perfect binary trees.

669


How do you define a string?

649






Write a code to remove duplicates in a string.

623


How does free() know explain how much memory to release?

616


Write a C/C++ program to add a user to MySQL. The user should be permitted to only "INSERT" into the given database.

1491


What are the characteristics of arrays in c?

609


Explain how can I avoid the abort, retry, fail messages?

587


What is the correct code to have following output in c using nested for loop?

609


What is c++ used for today?

661


how do you execute a c program in unix.

636


Write a C program in Fibonacci series.

629


What is memcpy() function?

620