Skip to content

Repository files navigation

Hedgehog Test

Table of Contents

Description

This project is a console-based application built with C# using Visual Studio. The program simulates the management of hedgehog populations across different colonies, performing population adjustments based on user input. The goal is to find the number of rounds needed to balance the populations of different colonies. The program also includes input validation and error handling to ensure proper interaction.

Key Features:

  • Input population sizes for three hedgehog colonies.
  • Simulate population balance based on user-selected target colonies.
  • Handle edge cases and invalid inputs effectively.
  • Display results at the end of the simulation.

Task

You can find the task details here.

Technologies Used

  • C#: The main programming language used to build this application.
  • Visual Studio 2022: The IDE used for development and debugging.
  • Git: For version control.

Getting Started

To get started with this project, follow these steps:

  1. Clone the repository to your local machine:
    git clone https://github.com/gadiim/HedgehokTest.git
  2. Open the solution in Visual Studio 2022.
  3. Build and run the project:
    • Press Ctrl + Shift + B to build the project.
    • Press Ctrl + F5 to run it without debugging, or F5 to run it with debugging.
  4. Follow the on-screen instructions to input population sizes for the hedgehog colonies and perform the necessary actions.

Usage

  1. When you run the program, you will be prompted to enter the population of three hedgehog colonies.
  2. After that, you will select which colony should be the target for population balancing.
  3. The program will simulate population transfers until the colonies are balanced or the operation is deemed impossible.
  4. The final number of rounds and the state of the colonies will be displayed at the end of the simulation.

License

This project is licensed under the MIT License. You are free to use, modify, and distribute this project. See the LICENSE file for more details. MIT License

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Acknowledgements

  • This project was developed as part of a personal learning exercise.
  • Special thanks to the Visual Studio team and the C# community for their excellent documentation and tools. 😊

About

C# application that simulates hedgehog colony population dynamics, allowing users to input data, compare populations, and track their evolution over multiple rounds.

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages