CSE102#HW09

$30.00

Category: You will Instantly receive a download link for .zip solution file upon Payment || To Order Original Work Click Custom Order?

Description

5/5 - (5 votes)

Write a C program that keeps information about world countries. There could be at most 100 countries. Use
C Structures with the following data fields to represent countries.
 Country name (at 25 characters),
 Country population,
 Country area in km squares,
 Number of soldiers in the army,
 Neighbor countries (at most 10 neighbors, 0 for island countries)
When your program runs, it should offer the following options
(a) Add a country (if user presses corresponding key, in this case: ‘a’), (Type ‘-1’ to finish
neighbor input )
(b) Print name of the most powerful country in terms of military strength in vicinity of a given
country (among neighbors of neighbors of given country including itself )
(c) Print name of the largest country in terms of land it possesses in vicinity of a given country
(among neighbors of neighbors of given country including itself )
(d) Calculates and prints how many people at minimum should be seen if I need to go from a
given country to another given country (Assume that if I visit a country, I would see all
people of that country). If the target country is inaccessible then print INACCESSIBLE.
(e) Exit the program (Presses key ‘e’)
Sample Usage
Make your choice:
a
Turkiye
79000000
815000
640000
Azerbaycan
Bulgaristan
Ermenistan
Gurcistan
Irak
Iran
Suriye
Yunanistan
-1
Make your choice:
b
Turkiye
Turkiye
Make your choice:
c
Turkiye
Turkiye
Make your choice:
d
Turkiye Bulgaristan
INACCESSIBLE
Make your choice:
e
Good Bye
#notes
 You should send your main function completely.
 The assignment must be your original work. Duplicate or very similar assignments are both
going to be considered as cheating.
 Ask your questions via moodle.