Skip to content

Add square root calculation functionality#5

Draft
Copilot wants to merge 3 commits into
mainfrom
copilot/fix-2
Draft

Add square root calculation functionality#5
Copilot wants to merge 3 commits into
mainfrom
copilot/fix-2

Conversation

Copilot AI commented May 23, 2025

Copy link
Copy Markdown
Contributor

This PR adds a new feature to calculate the square root of a number, as requested in the issue. The implementation includes:

  1. Added a new CalculateSquareRoot method in the DoMath class that:

    • Prompts the user to enter a number
    • Validates the input to ensure it's a valid positive number
    • Calculates the square root using Math.Sqrt() method
    • Displays the result and waits for user input before returning to the menu
  2. Updated the main menu to include a new option "7) Calculate square root"

  3. Updated the switch statement in the MainMenu method to handle the new option

  4. Added a .gitignore file to exclude build artifacts from future commits

How to test

  1. Run the application
  2. Select option 7 from the main menu
  3. Enter a positive number
  4. Verify the square root is calculated and displayed correctly

Fixes #2.

Warning

Firewall rules blocked me from connecting to one or more addresses

I tried to connect to the following addresses, but was blocked by firewall rules:

  • crl3.digicert.com
    • Triggering command: dotnet build (dns block)
  • crl4.digicert.com
    • Triggering command: dotnet build (dns block)
  • ocsp.digicert.com
    • Triggering command: dotnet build (dns block)
  • s.symcb.com
    • Triggering command: dotnet build (dns block)
  • s.symcd.com
    • Triggering command: dotnet build (dns block)
  • ts-crl.ws.symantec.com
    • Triggering command: dotnet build (dns block)
  • ts-ocsp.ws.symantec.com
    • Triggering command: dotnet build (dns block)

If you need me to access, download, or install something from one of these locations, you can either:


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits May 23, 2025 07:38
Co-authored-by: referencenull <5699046+referencenull@users.noreply.github.com>
Co-authored-by: referencenull <5699046+referencenull@users.noreply.github.com>
Copilot AI changed the title [WIP] Add new functionality to calculate square root Add square root calculation functionality May 23, 2025
Copilot AI requested a review from referencenull May 23, 2025 07:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add new functionality to calculate square root

2 participants