Answered step by step
Verified Expert Solution
Question
1 Approved Answer
University of Wollongong School of Computing and Information Technology CSCI 2 5 1 Advanced Programming Processing requirements - Display City Map Realistically, there is limited
University of Wollongong
School of Computing and Information Technology
CSCI Advanced Programming
Processing requirements Display City Map
Realistically, there is limited graphical display capabilities available when you are constrained to displaying output on Ubuntu shell's terminal. Figure B below illustrates the actual display formatting requirements when user selects the "Display City Map" option from your program's menu.
Fig. B
Note :
i
The city id is displayed on the relevant grid areas, instead of city names!
ii
Refer to Fig. B which describes how each city's id value is stored in the input file
iii
The entire extent of the map is bounded by the # char
a As discussed in earlier Appendix A Fig. A the range values for variables 'GridXIdxRange' and 'GridYIdxRange' can vary.
This implies the size and shape of your map display can change as well eg it is possible to have a large 'rectangular' shaped gridarea map!
Therefore, please do not assume "hard code" any constant values for your array sizes to store your map data!
b You must make use of basic array, and dynamic memory allocation research on how to use 'new' to initialize the size of your arrays during program runtime, to store all relevant weather map data.
c The type of the array eg int, double, struct, etc is up to you, and there is no restriction on how many arrays you think is necessary to store all the relevant weather data.
d Before your program exit, you must deallocate all memory that was dynamically allocated by you during runtime research on how to use 'delete' Failure to do so results in memory leak and marks deduction!
Page of
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started