Create a struct called airport with the identifier fields

Assignment Help Computer Engineering
Reference no: EM131299715

Airport information.

Create a struct called Airport with the following fields:

Identifier. This should be an array of four character or a pointer to an array of characters.

The following properties are doubles:

Coordinates which consist of Latitude and Longitude. Latitude is positive to indicate is North of the Equator and negative when it's located in the southern hemisphere. Longitude is negative to indicate is West and positive to indicate it's East of the Greenwich median.

A magnetic variation which also is indicated negative for West and positive for East. It is OK to have no magnetic variation.

Elevation above sea level in feet.

For example San Diego airport has the values ID: SAN, Lat: 32.7335556, Long: -117.1896667, Var: 14, Elev: 16.8' (https://www.airnav.com/airport/SAN)

Also create a method inside the structure called getDistance that takes four doubles and use the formula from Project 1.

Create another method inside the structure called getDistance2, this method should take one and only one Airport as parameter. This method should break down the elements of each airport and call the getDistance method to return the distance in nautical miles.

To test your program, you will declare two Airport variables and will ask the user to enter their ID, Coordinates, Elevation and Magnetic Variation. Then you will calculate the distance between the two using the getDistance2 method. Assuming the user entered the values below, the program should work if it had the following code:

// Variable declaration

double dist;

Airport SAN, SFO;

// // User input

SAN.Latitude = 32.7335556;

SAN.Longitude = -117.1896667;

SFO.Latitude = 37.6188056;

SFO.Longitude = -122.3754167;

// Calculations

dist = SAN.getDistance2(SFO);

Don't forget your documentation.

Reference no: EM131299715

Questions Cloud

Explain the advantages of leasing : They will be leasing the vehicles as opposed to purchasing them outright. Please explain the advantages of leasing and which lease type would be more preferable?
Identify data that you could store and the length of time : Identify the data that you could store and the length of time in which you should store it. You may be asked to report on weekly, monthly, or yearly average temperatures.
Determining the payroll package : Ahmad is an analyst. The human resources department is very unhappy with their payroll package. They want the information systems department to write them a new package as they think they have unique needs. What should Ahmad do?
Identify all its brand elements and assess their ability : Pick a brand. Identify all its brand elements and assess their ability to contribute to brand equity according to the choice criteria identified.
Create a struct called airport with the identifier fields : Create a struct called Airport with the following fields: Identifier. This should be an array of four character or a pointer to an array of characters.
Make strong contributions to brand equity : What are some other examples of slogans not listed in that make strong contributions to brand equity? Why? Can you think of any "bad" slogans? Why do you consider them to be so?
Guidelines to help marketers mix and match brand elements : Can you think of some general guidelines to help marketers mix and match brand elements? Can you ever have "too many" brand elements?
What the weighted average cost of capital is : As her CFO, your excellent services are called upon, yet again. How would you explain to her what the weighted average cost of capital is and how it is calculated?
Have you had any experience with a brand : Have you had any experience with a brand that has done a great job with relationship marketing, permission marketing, experiential marketing, or one-to-one marketing?

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd