From 844625fb80869c242b9b15e70ec5596cf904f1d6 Mon Sep 17 00:00:00 2001 From: Dovine Owuor <70941806+Dovineowuor@users.noreply.github.com> Date: Tue, 13 Jun 2023 03:12:06 +0300 Subject: [PATCH] Update README.md --- README.md | 82 +++++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 74 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 2bf1934..d8152d1 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,79 @@ -# HTML/CSS/JS Replit Extensions Starter +# Air Distance Calculator -This is an HTML/CSS/JS Extension Starter which includes a few simple API calls. +The Air Distance Calculator is a simple Python program that calculates the distance between two locations on the Earth using their latitude and longitude coordinates. It utilizes the Haversine formula to accurately calculate the shortest distance between two points on a sphere. - - [Documentation](https://docs.replit.com/extensions) - - [API Reference](https://docs.replit.com/extensions/category/api-reference) +## Features + +- Calculate the air distance between two locations specified by latitude and longitude coordinates. +- Provide inputs in decimal degrees format for latitude and longitude. +- Display the distance in kilometers (km) or miles (mi). ## Getting Started -1. Fork this Repl if you have not done so already -2. Click the **Extension Devtools** button in the top-right corner of the workspace -3. Under **Tools**, click **Open** -4. Start developing your extension \ No newline at end of file +### Prerequisites + +To run the Air Distance Calculator, make sure you have the following installed on your system: + +- Python 3.x + +### Installation + +1. Clone the repository: + + ```shell + git clone https://github.com/Dovineowuor/Air-Distance-Claculator.git + ``` + +2. Navigate to the project directory: + + ```shell + cd Air-Distance-Claculator + ``` + +3. Run the program: + + ```shell + python air_distance_calculator.py + ``` + +## Usage + +1. Enter the latitude and longitude coordinates for the starting location. +2. Enter the latitude and longitude coordinates for the destination location. +3. Select the unit of measurement (kilometers or miles) to display the distance. +4. The program will calculate and display the air distance between the two locations. + +## Examples + +``` +Enter the latitude and longitude for the starting location: +Latitude: 51.5074 +Longitude: -0.1278 + +Enter the latitude and longitude for the destination location: +Latitude: 48.8566 +Longitude: 2.3522 + +Select the unit of measurement: +1. Kilometers +2. Miles +Choice: 1 + +The air distance between the two locations is 342.16 km. +``` + +## Contributing + +Contributions to the Air Distance Calculator project are welcome! If you have any ideas, suggestions, or bug reports, please open an issue or submit a pull request. + +## License + +This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more information. + +## Acknowledgements + +The Air Distance Calculator project is inspired by the Haversine formula and serves as a simple demonstration of its implementation in Python. + +--- + +Feel free to customize this README file according to your project's specific details, instructions, and requirements.