/CSharp-Project-branching-looping

In correspondence with: Add logic to C# console applications (Get started with C#, Part 3)

Primary LanguageC#

CSharp-Project-branching-looping

Introduction

This project sourced from Microsoft Learn, equivalent to Add logic to C# console applications (Get started with C#, Part 3)

Navigate to Microsoft Learn

This project is to create a console application about animal data, to display the collection of the stored animals, to add new animal into the collection, to update information of animals which met the conditions.

There are in total 8 options on the menu after the program is loaded:

  1. List all of our current pet information
  2. Add a new animal friend to the ourAnimals array
  3. Ensure animal ages and physical descriptions are complete
  4. Ensure animal nicknames and personality descriptions are complete
  5. Edit an animal's age
  6. Edit an animal's personality description
  7. Display all cats with their characteristics
  8. Display all dogs with their characteristics

This repository is composed of 3 parts:

  • Guided Project (Task 1-2)
  • Challenge Project (Task 3-4)
  • Complete version (Task 1-8)

Guided Project

The folder contains documents about the license and README from Microsoft, and a sub folder named "GuidedProject". Inside "GuidedProject", you can find 2 subfolders: "Final" and "Starter". Final folder contains the finished part (covering Task 1-2) suggested by Microsoft for reference. Starter folder contains my work.

Challenge Project

The folder contains documents about the license and README from Microsoft, and a sub folder named "ChallengedProject". Inside "ChallengedProject", you can find 2 subfolders: "Final" and "Starter". Final folder contains the finished part (covering Task 3-4) suggested by Microsoft for reference. Starter folder contains my work.

Complete Project

Inside the subfolder of "contozo_animal_family" (temp name I created), you can find the executable file Program.cs to check my work or run it in your local environment.

How to run the program in the local environment

This repository requires .NET runtime installed in the local environment to run it.

I have installed .NET in my computer

Please download the zip file of this repository or use git clone command with the URL to clone it to your drive. Go to the targeted folder, you can either run it in your terminal or open with your preferred IDE (for example Viscual Studio / Visual Studio Code). If you want to run it in the terminal, use dotnet run to build and run it. If you want to run it inside your preferred IDE, like Visual Studio, you can navigate yourself to debug in the top menu bar, and click start debugging.

I have not installed .NET in my computer

Please go to the link below which leads you back to Microsoft, follow the instructions and install .NET in your computer.

Install .NET on Windows, Linux, and macOS