Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
bin/
obj/
18 changes: 18 additions & 0 deletions BusinessApp/Mathoperations.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,22 @@ public void IsP()
Console.ReadKey();
}

public void CalculateSquareRoot()
{
Console.Write("Enter a number: ");
string input = Console.ReadLine();

if (double.TryParse(input, out double number) && number >= 0)
{
double sqrtResult = Math.Sqrt(number);
Console.WriteLine("Square root of {0} is: {1}", number, sqrtResult);
}
else
{
Console.WriteLine("Invalid input. Please enter a valid positive number.");
}

Console.WriteLine("Press Enter to return to the main menu.");
Console.ReadLine();
}
}
72 changes: 38 additions & 34 deletions BusinessApp/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,41 +17,45 @@ private static bool MainMenu()
Printoperations p = new Printoperations();
DoMath d = new DoMath();

Console.Clear();
Console.WriteLine("Choose an option:");
Console.WriteLine("1) Reverse String");
Console.WriteLine("2) Remove Whitespace");
Console.WriteLine("3) Print");
Console.WriteLine("4) Print star");
Console.WriteLine("5) Calculate area");
Console.WriteLine("6) Is number p");
Console.WriteLine("0) Exit");
Console.Write("\r\nSelect an option: ");
Console.Clear();
Console.WriteLine("Choose an option:");
Console.WriteLine("1) Reverse String");
Console.WriteLine("2) Remove Whitespace");
Console.WriteLine("3) Print");
Console.WriteLine("4) Print star");
Console.WriteLine("5) Calculate area");
Console.WriteLine("6) Is number p");
Console.WriteLine("7) Calculate square root");
Console.WriteLine("0) Exit");
Console.Write("\r\nSelect an option: ");

switch (Console.ReadLine())
{
case "1":
ReverseString();
return true;
case "2":
RemoveWhitespace();
return true;
case "3":
p.PrintSomething();
return true;
case "4":
p.PrintS();
return true;
case "5":
d.Area();
return true;
case "6":
d.IsP();
return true;
case "0":
return false;
default:
return true;
switch (Console.ReadLine())
{
case "1":
ReverseString();
return true;
case "2":
RemoveWhitespace();
return true;
case "3":
p.PrintSomething();
return true;
case "4":
p.PrintS();
return true;
case "5":
d.Area();
return true;
case "6":
d.IsP();
return true;
case "7":
d.CalculateSquareRoot();
return true;
case "0":
return false;
default:
return true;
}
}
private static string CaptureInput()
Expand Down
Binary file modified BusinessApp/bin/Debug/net7.0/BusinessApp
Binary file not shown.
Binary file modified BusinessApp/bin/Debug/net7.0/BusinessApp.dll
Binary file not shown.
Binary file modified BusinessApp/bin/Debug/net7.0/BusinessApp.pdb
Binary file not shown.
30 changes: 22 additions & 8 deletions BusinessApp/obj/BusinessApp.csproj.nuget.dgspec.json
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
{
"format": 1,
"restore": {
"/workspaces/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj": {}
"/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj": {}
},
"projects": {
"/workspaces/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj": {
"/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "/workspaces/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"projectUniqueName": "/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"projectName": "BusinessApp",
"projectPath": "/workspaces/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"packagesPath": "/home/codespace/.nuget/packages/",
"outputPath": "/workspaces/ItWorksDoNotTouch/BusinessApp/obj/",
"projectPath": "/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"packagesPath": "/home/runner/.nuget/packages/",
"outputPath": "/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/",
"projectStyle": "PackageReference",
"configFilePaths": [
"/home/codespace/.nuget/NuGet/NuGet.Config"
"/home/runner/.nuget/NuGet/NuGet.Config"
],
"originalTargetFrameworks": [
"net7.0"
Expand Down Expand Up @@ -58,12 +58,26 @@
],
"assetTargetFallback": true,
"warn": true,
"downloadDependencies": [
{
"name": "Microsoft.AspNetCore.App.Ref",
"version": "[7.0.20, 7.0.20]"
},
{
"name": "Microsoft.NETCore.App.Host.linux-x64",
"version": "[7.0.20, 7.0.20]"
},
{
"name": "Microsoft.NETCore.App.Ref",
"version": "[7.0.20, 7.0.20]"
}
],
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "/usr/local/dotnet/7.0.306/sdk/7.0.306/RuntimeIdentifierGraph.json"
"runtimeIdentifierGraphPath": "/usr/lib/dotnet/sdk/8.0.115/RuntimeIdentifierGraph.json"
}
}
}
Expand Down
8 changes: 4 additions & 4 deletions BusinessApp/obj/BusinessApp.csproj.nuget.g.props
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
<RestoreSuccess Condition=" '$(RestoreSuccess)' == '' ">True</RestoreSuccess>
<RestoreTool Condition=" '$(RestoreTool)' == '' ">NuGet</RestoreTool>
<ProjectAssetsFile Condition=" '$(ProjectAssetsFile)' == '' ">$(MSBuildThisFileDirectory)project.assets.json</ProjectAssetsFile>
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">/home/codespace/.nuget/packages/</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">/home/codespace/.nuget/packages/</NuGetPackageFolders>
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">/home/runner/.nuget/packages/</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">/home/runner/.nuget/packages/</NuGetPackageFolders>
<NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.6.0</NuGetToolVersion>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.8.1</NuGetToolVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<SourceRoot Include="/home/codespace/.nuget/packages/" />
<SourceRoot Include="/home/runner/.nuget/packages/" />
</ItemGroup>
</Project>
2 changes: 1 addition & 1 deletion BusinessApp/obj/Debug/net7.0/BusinessApp.AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
[assembly: System.Reflection.AssemblyCompanyAttribute("BusinessApp")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+47a4dd73b70f07a413efd2a2f95c8aa02e29c452")]
[assembly: System.Reflection.AssemblyProductAttribute("BusinessApp")]
[assembly: System.Reflection.AssemblyTitleAttribute("BusinessApp")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
08b444d6e48b75c761b3fc97398b9105d3e7ad3c
89e7f77dc2f77f9dd1ccfbe217c9fc7cceb3a6e55b3238e2c56b3ad80459f95f
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,6 @@ build_property.PlatformNeutralAssembly =
build_property.EnforceExtendedAnalyzerRules =
build_property._SupportedPlatformList = Linux,macOS,Windows
build_property.RootNamespace = BusinessApp
build_property.ProjectDir = /workspaces/ItWorksDoNotTouch/BusinessApp/
build_property.ProjectDir = /home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/
build_property.EnableComHosting =
build_property.EnableGeneratedComInterfaceComImportInterop =
Binary file modified BusinessApp/obj/Debug/net7.0/BusinessApp.assets.cache
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1 +1 @@
72f1d53ab4f3636dbd8562800a13ea5b5a5ce1fc
b7b499f64ff14c368378469c211ab1b42d27ef4e17ef91d17aa30d30b13b0ded
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,25 @@
/workspaces/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/Azure.Core.dll
/workspaces/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/Microsoft.Bcl.AsyncInterfaces.dll
/workspaces/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/System.Memory.Data.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/BusinessApp
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/BusinessApp.deps.json
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/BusinessApp.runtimeconfig.json
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/BusinessApp.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/BusinessApp.pdb
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/Azure.AI.OpenAI.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/Azure.Core.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/Microsoft.Bcl.AsyncInterfaces.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/Newtonsoft.Json.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/bin/Debug/net7.0/System.Memory.Data.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.csproj.AssemblyReference.cache
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.GeneratedMSBuildEditorConfig.editorconfig
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.AssemblyInfoInputs.cache
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.AssemblyInfo.cs
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.csproj.CoreCompileInputs.cache
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.sourcelink.json
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.csproj.CopyComplete
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/refint/BusinessApp.dll
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.pdb
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/BusinessApp.genruntimeconfig.cache
/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/Debug/net7.0/ref/BusinessApp.dll
Binary file modified BusinessApp/obj/Debug/net7.0/BusinessApp.dll
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0f2637de371ec776b9aa4a951b9b8212dad24786
9504a0134bb9126f3d904ecc797339deb864724c7b9664ecf3344390594de218
Binary file modified BusinessApp/obj/Debug/net7.0/BusinessApp.pdb
Binary file not shown.
1 change: 1 addition & 0 deletions BusinessApp/obj/Debug/net7.0/BusinessApp.sourcelink.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"documents":{"/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/*":"https://raw.githubusercontent.com/referencenull/ItWorksDoNotTouch/47a4dd73b70f07a413efd2a2f95c8aa02e29c452/*"}}
Binary file modified BusinessApp/obj/Debug/net7.0/apphost
Binary file not shown.
Binary file modified BusinessApp/obj/Debug/net7.0/ref/BusinessApp.dll
Binary file not shown.
Binary file modified BusinessApp/obj/Debug/net7.0/refint/BusinessApp.dll
Binary file not shown.
28 changes: 21 additions & 7 deletions BusinessApp/obj/project.assets.json
Original file line number Diff line number Diff line change
Expand Up @@ -388,19 +388,19 @@
]
},
"packageFolders": {
"/home/codespace/.nuget/packages/": {}
"/home/runner/.nuget/packages/": {}
},
"project": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "/workspaces/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"projectUniqueName": "/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"projectName": "BusinessApp",
"projectPath": "/workspaces/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"packagesPath": "/home/codespace/.nuget/packages/",
"outputPath": "/workspaces/ItWorksDoNotTouch/BusinessApp/obj/",
"projectPath": "/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"packagesPath": "/home/runner/.nuget/packages/",
"outputPath": "/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/obj/",
"projectStyle": "PackageReference",
"configFilePaths": [
"/home/codespace/.nuget/NuGet/NuGet.Config"
"/home/runner/.nuget/NuGet/NuGet.Config"
],
"originalTargetFrameworks": [
"net7.0"
Expand Down Expand Up @@ -444,12 +444,26 @@
],
"assetTargetFallback": true,
"warn": true,
"downloadDependencies": [
{
"name": "Microsoft.AspNetCore.App.Ref",
"version": "[7.0.20, 7.0.20]"
},
{
"name": "Microsoft.NETCore.App.Host.linux-x64",
"version": "[7.0.20, 7.0.20]"
},
{
"name": "Microsoft.NETCore.App.Ref",
"version": "[7.0.20, 7.0.20]"
}
],
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "/usr/local/dotnet/7.0.306/sdk/7.0.306/RuntimeIdentifierGraph.json"
"runtimeIdentifierGraphPath": "/usr/lib/dotnet/sdk/8.0.115/RuntimeIdentifierGraph.json"
}
}
}
Expand Down
29 changes: 16 additions & 13 deletions BusinessApp/obj/project.nuget.cache
Original file line number Diff line number Diff line change
@@ -1,20 +1,23 @@
{
"version": 2,
"dgSpecHash": "CXiGdRwuKqH4IIDLFZJ2SiXDKXborUU3zrYfjrsMLjwGVxxmWpgtDhViTOuqj/PFQZQFTiQCRV36tJ80LE4QyQ==",
"dgSpecHash": "iSp8XgrMcn37lB7g5ZVJs5GVNOClZGzv+xG95tSCIPGiao+9zIGren996GIXIHBvTv2LI1qSVh/QcRQyqaNFrg==",
"success": true,
"projectFilePath": "/workspaces/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"projectFilePath": "/home/runner/work/ItWorksDoNotTouch/ItWorksDoNotTouch/BusinessApp/BusinessApp.csproj",
"expectedPackageFiles": [
"/home/codespace/.nuget/packages/azure.ai.openai/1.0.0-beta.9/azure.ai.openai.1.0.0-beta.9.nupkg.sha512",
"/home/codespace/.nuget/packages/azure.core/1.35.0/azure.core.1.35.0.nupkg.sha512",
"/home/codespace/.nuget/packages/microsoft.bcl.asyncinterfaces/1.1.1/microsoft.bcl.asyncinterfaces.1.1.1.nupkg.sha512",
"/home/codespace/.nuget/packages/newtonsoft.json/13.0.3/newtonsoft.json.13.0.3.nupkg.sha512",
"/home/codespace/.nuget/packages/system.diagnostics.diagnosticsource/6.0.1/system.diagnostics.diagnosticsource.6.0.1.nupkg.sha512",
"/home/codespace/.nuget/packages/system.memory.data/1.0.2/system.memory.data.1.0.2.nupkg.sha512",
"/home/codespace/.nuget/packages/system.numerics.vectors/4.5.0/system.numerics.vectors.4.5.0.nupkg.sha512",
"/home/codespace/.nuget/packages/system.runtime.compilerservices.unsafe/6.0.0/system.runtime.compilerservices.unsafe.6.0.0.nupkg.sha512",
"/home/codespace/.nuget/packages/system.text.encodings.web/4.7.2/system.text.encodings.web.4.7.2.nupkg.sha512",
"/home/codespace/.nuget/packages/system.text.json/4.7.2/system.text.json.4.7.2.nupkg.sha512",
"/home/codespace/.nuget/packages/system.threading.tasks.extensions/4.5.4/system.threading.tasks.extensions.4.5.4.nupkg.sha512"
"/home/runner/.nuget/packages/azure.ai.openai/1.0.0-beta.9/azure.ai.openai.1.0.0-beta.9.nupkg.sha512",
"/home/runner/.nuget/packages/azure.core/1.35.0/azure.core.1.35.0.nupkg.sha512",
"/home/runner/.nuget/packages/microsoft.bcl.asyncinterfaces/1.1.1/microsoft.bcl.asyncinterfaces.1.1.1.nupkg.sha512",
"/home/runner/.nuget/packages/newtonsoft.json/13.0.3/newtonsoft.json.13.0.3.nupkg.sha512",
"/home/runner/.nuget/packages/system.diagnostics.diagnosticsource/6.0.1/system.diagnostics.diagnosticsource.6.0.1.nupkg.sha512",
"/home/runner/.nuget/packages/system.memory.data/1.0.2/system.memory.data.1.0.2.nupkg.sha512",
"/home/runner/.nuget/packages/system.numerics.vectors/4.5.0/system.numerics.vectors.4.5.0.nupkg.sha512",
"/home/runner/.nuget/packages/system.runtime.compilerservices.unsafe/6.0.0/system.runtime.compilerservices.unsafe.6.0.0.nupkg.sha512",
"/home/runner/.nuget/packages/system.text.encodings.web/4.7.2/system.text.encodings.web.4.7.2.nupkg.sha512",
"/home/runner/.nuget/packages/system.text.json/4.7.2/system.text.json.4.7.2.nupkg.sha512",
"/home/runner/.nuget/packages/system.threading.tasks.extensions/4.5.4/system.threading.tasks.extensions.4.5.4.nupkg.sha512",
"/home/runner/.nuget/packages/microsoft.netcore.app.ref/7.0.20/microsoft.netcore.app.ref.7.0.20.nupkg.sha512",
"/home/runner/.nuget/packages/microsoft.aspnetcore.app.ref/7.0.20/microsoft.aspnetcore.app.ref.7.0.20.nupkg.sha512",
"/home/runner/.nuget/packages/microsoft.netcore.app.host.linux-x64/7.0.20/microsoft.netcore.app.host.linux-x64.7.0.20.nupkg.sha512"
],
"logs": []
}