Question: ALL ANSWERS CODE SHOULD BE IN C LANGUAGE Question No.2: [05 Marks] Research our planet population growing issues online. Get approximations for the current population
ALL ANSWERS CODE SHOULD BE IN C LANGUAGE
Question No.2: [05 Marks]
Research our planet population growing issues online. Get approximations for the current population and its growing rate (the percentage by which its likely to increase this year). Write a program that calculates
a) World population growth each year for the next 25 years, using the supposition that the current growth rate will remain unchanged.
b) Print the results in a table. The first column should display the year from year 1 to year 25. The second column should display the anticipated world population at the end of that year. The third column should display the numerical increase in the world population that would occur that year.
Question No.3: [05 Marks]
Write a function to convert temperature from Fahrenheit to Celsius named ConvertFtoC that takes one double value for Fahrenheit as argument, and returns the equivalent temperature in Celsius(type double). Create a program that exercise this function by obtaining a Fahrenheit value from the user, calling the function, and displaying the value of Celsius it returns. [Formula: Celsius = (Fahrenheit 32 ) * 5/9 ]
Question No.4: [05 Marks]
A food based company wants their users to rate their newly launched food items, items are
Burger, Broast, Rice, Roll, Handi, Platter, Kebabs, Sandwich, Shake, Kheer.
Scoring can be done from 1 to 10, best towards worst respectively. Design a solution that saves the food items and then let users rate these food items along with their comments. A bar graph based on rating should also be printed
Note: (Structures must be used to save the data)
A sample run of the application is shown as follows:
Enter score for Burger (1-10)
8
Enter reason for liking or disliking
Fresh and juicy
Output of your program should be as follows
Item Rating Reason Histogram
| Burger. | 8 | Fresh and juicy | ******** |
| Broast | 4 | Taste was not good | **** |
| . | . | . | . |
| . | . | . | . |
Question No.5: [05 Marks]
Suppose we have a file STD.doc containing roll numbers, name and marks of some students. Write a program to read the name of a student and check whether the record of this student I available in this file. If the record is available then print it with an appropriate message, otherwise print the message Record does not exist.
Question No.6: [05 Marks]
Suppose three numbers x, y, z are passed to a function. Implement this function to assign the values of y to x, z to y and x to z and return these three changed values to main. Use pointer.
Question No.7: [05 Marks]
A formatted file master.txt contains the employee code, name and basic pay of employees of an organization. Write a program to calculate the D.A(dearness allowance), H.R.A (House rent allowance) and gross income of each employee and store employee code, name, basic pay, D.A,H.R.A and gross income to the file emp.txt, where D.A is the 32% of basic pay, H.R.A is 15% of basic pay and gross pay is the sum of basic pay, D.A and H.R.A.
Question No.8: [05 Marks]
Create a structure called Students that holds information like Registration code, name of student and date of admission. Write a program to create an array of structures and enter some data into it (15 records at least). Then ask the user to enter current date. Display the names of those Students who are in the school greater than or equal to 5 years.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
