瀏覽代碼

создали пустой проект

Ruslan Antonov 2 年之前
當前提交
13b8a1f1bf

二進制
.vs/AntonovLab9/v17/.suo


+ 25 - 0
AntonovLab9.sln

@@ -0,0 +1,25 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.3.32922.545
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AntonovLab9", "AntonovLab9\AntonovLab9.csproj", "{C3F7B116-1FFD-43B5-AEC2-B9C4EEDCDF97}"
+EndProject
+Global
+	GlobalSection(SolutionConfigurationPlatforms) = preSolution
+		Debug|Any CPU = Debug|Any CPU
+		Release|Any CPU = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(ProjectConfigurationPlatforms) = postSolution
+		{C3F7B116-1FFD-43B5-AEC2-B9C4EEDCDF97}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{C3F7B116-1FFD-43B5-AEC2-B9C4EEDCDF97}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{C3F7B116-1FFD-43B5-AEC2-B9C4EEDCDF97}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{C3F7B116-1FFD-43B5-AEC2-B9C4EEDCDF97}.Release|Any CPU.Build.0 = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(SolutionProperties) = preSolution
+		HideSolutionNode = FALSE
+	EndGlobalSection
+	GlobalSection(ExtensibilityGlobals) = postSolution
+		SolutionGuid = {F83A6397-AB8A-4558-AD33-48E2366E3FCB}
+	EndGlobalSection
+EndGlobal

+ 10 - 0
AntonovLab9/AntonovLab9.csproj

@@ -0,0 +1,10 @@
+<Project Sdk="Microsoft.NET.Sdk">
+
+  <PropertyGroup>
+    <OutputType>Exe</OutputType>
+    <TargetFramework>net6.0</TargetFramework>
+    <ImplicitUsings>enable</ImplicitUsings>
+    <Nullable>enable</Nullable>
+  </PropertyGroup>
+
+</Project>

+ 34 - 0
AntonovLab9/Program.cs

@@ -0,0 +1,34 @@
+using System;
+
+namespace Summa
+{
+    class Program
+    {
+        public static void Main(string[] args)
+        {
+            Console.WriteLine("Введите натуральное число N"); //Вывод на экран данного сообщения
+            int N = Convert.ToInt32(Console.ReadLine()); //Пользователь вводит N, программа считывает и конвертирует string в int 
+            int n = N, //Написал int n = N, так как если делать сразу через n, программа не воспринимает sum за локальную переменную
+
+                sum = 0; //В начале сумма натуральных чисел = 0, так как ни одно число ещё не было введено
+            if (N <= 0) //На случай, если пользователь введёт N<=0, т.е ненатуральное
+            {
+                Console.WriteLine("Это ненатуральное число"); //То в окне отображается данное сообщение
+            }
+
+            for (int i = 1; i <= n; i++) // Условие цикла: количество итераций, которые должны выполниться в цикле = 1; если i<=n, произойдет выход из цикла; i++ присваивает, а затем увеличивает значение";
+            {
+                // sum = sum + i
+                sum += i; //Внутри цикла значение переменной sum увеличивается на i 
+            }
+            if (N > 0) //Если N>0
+
+            {
+                Console.WriteLine("Сумма первых {0} натуральных чисел = {1}", n, sum); // То на экране отображается данное сообщение
+            }
+
+            Console.ReadLine(); // Пустая строка ввода, чтобы окно программы не закрылось
+        }
+    }
+}
+

+ 67 - 0
AntonovLab9/obj/AntonovLab9.csproj.nuget.dgspec.json

@@ -0,0 +1,67 @@
+{
+  "format": 1,
+  "restore": {
+    "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\AntonovLab9.csproj": {}
+  },
+  "projects": {
+    "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\AntonovLab9.csproj": {
+      "version": "1.0.0",
+      "restore": {
+        "projectUniqueName": "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\AntonovLab9.csproj",
+        "projectName": "AntonovLab9",
+        "projectPath": "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\AntonovLab9.csproj",
+        "packagesPath": "C:\\Users\\User\\.nuget\\packages\\",
+        "outputPath": "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\obj\\",
+        "projectStyle": "PackageReference",
+        "fallbackFolders": [
+          "C:\\Program Files (x86)\\Microsoft Visual Studio\\Shared\\NuGetPackages"
+        ],
+        "configFilePaths": [
+          "C:\\Users\\User\\AppData\\Roaming\\NuGet\\NuGet.Config",
+          "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.FallbackLocation.config",
+          "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
+        ],
+        "originalTargetFrameworks": [
+          "net6.0"
+        ],
+        "sources": {
+          "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
+          "https://api.nuget.org/v3/index.json": {}
+        },
+        "frameworks": {
+          "net6.0": {
+            "targetAlias": "net6.0",
+            "projectReferences": {}
+          }
+        },
+        "warningProperties": {
+          "warnAsError": [
+            "NU1605"
+          ]
+        }
+      },
+      "frameworks": {
+        "net6.0": {
+          "targetAlias": "net6.0",
+          "imports": [
+            "net461",
+            "net462",
+            "net47",
+            "net471",
+            "net472",
+            "net48",
+            "net481"
+          ],
+          "assetTargetFallback": true,
+          "warn": true,
+          "frameworkReferences": {
+            "Microsoft.NETCore.App": {
+              "privateAssets": "all"
+            }
+          },
+          "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.401\\RuntimeIdentifierGraph.json"
+        }
+      }
+    }
+  }
+}

+ 16 - 0
AntonovLab9/obj/AntonovLab9.csproj.nuget.g.props

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8" standalone="no"?>
+<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <PropertyGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
+    <RestoreSuccess Condition=" '$(RestoreSuccess)' == '' ">True</RestoreSuccess>
+    <RestoreTool Condition=" '$(RestoreTool)' == '' ">NuGet</RestoreTool>
+    <ProjectAssetsFile Condition=" '$(ProjectAssetsFile)' == '' ">$(MSBuildThisFileDirectory)project.assets.json</ProjectAssetsFile>
+    <NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">$(UserProfile)\.nuget\packages\</NuGetPackageRoot>
+    <NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">C:\Users\User\.nuget\packages\;C:\Program Files (x86)\Microsoft Visual Studio\Shared\NuGetPackages</NuGetPackageFolders>
+    <NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
+    <NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.3.0</NuGetToolVersion>
+  </PropertyGroup>
+  <ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
+    <SourceRoot Include="C:\Users\User\.nuget\packages\" />
+    <SourceRoot Include="C:\Program Files (x86)\Microsoft Visual Studio\Shared\NuGetPackages\" />
+  </ItemGroup>
+</Project>

+ 2 - 0
AntonovLab9/obj/AntonovLab9.csproj.nuget.g.targets

@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="utf-8" standalone="no"?>
+<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />

+ 4 - 0
AntonovLab9/obj/Debug/net6.0/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs

@@ -0,0 +1,4 @@
+// <autogenerated />
+using System;
+using System.Reflection;
+[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v6.0", FrameworkDisplayName = "")]

+ 23 - 0
AntonovLab9/obj/Debug/net6.0/AntonovLab9.AssemblyInfo.cs

@@ -0,0 +1,23 @@
+//------------------------------------------------------------------------------
+// <auto-generated>
+//     Этот код создан программой.
+//     Исполняемая версия:4.0.30319.42000
+//
+//     Изменения в этом файле могут привести к неправильной работе и будут потеряны в случае
+//     повторной генерации кода.
+// </auto-generated>
+//------------------------------------------------------------------------------
+
+using System;
+using System.Reflection;
+
+[assembly: System.Reflection.AssemblyCompanyAttribute("AntonovLab9")]
+[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
+[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
+[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
+[assembly: System.Reflection.AssemblyProductAttribute("AntonovLab9")]
+[assembly: System.Reflection.AssemblyTitleAttribute("AntonovLab9")]
+[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
+
+// Создано классом WriteCodeFragment MSBuild.
+

+ 1 - 0
AntonovLab9/obj/Debug/net6.0/AntonovLab9.AssemblyInfoInputs.cache

@@ -0,0 +1 @@
+00c45b74060d7e9aecfbf43c9bf8901767903edf

+ 10 - 0
AntonovLab9/obj/Debug/net6.0/AntonovLab9.GeneratedMSBuildEditorConfig.editorconfig

@@ -0,0 +1,10 @@
+is_global = true
+build_property.TargetFramework = net6.0
+build_property.TargetPlatformMinVersion = 
+build_property.UsingMicrosoftNETSdkWeb = 
+build_property.ProjectTypeGuids = 
+build_property.InvariantGlobalization = 
+build_property.PlatformNeutralAssembly = 
+build_property._SupportedPlatformList = Linux,macOS,Windows
+build_property.RootNamespace = AntonovLab9
+build_property.ProjectDir = C:\Users\User\Source\Repos\AntonovLab9\AntonovLab9\

+ 8 - 0
AntonovLab9/obj/Debug/net6.0/AntonovLab9.GlobalUsings.g.cs

@@ -0,0 +1,8 @@
+// <auto-generated/>
+global using global::System;
+global using global::System.Collections.Generic;
+global using global::System.IO;
+global using global::System.Linq;
+global using global::System.Net.Http;
+global using global::System.Threading;
+global using global::System.Threading.Tasks;

二進制
AntonovLab9/obj/Debug/net6.0/AntonovLab9.assets.cache


二進制
AntonovLab9/obj/Debug/net6.0/AntonovLab9.csproj.AssemblyReference.cache


+ 73 - 0
AntonovLab9/obj/project.assets.json

@@ -0,0 +1,73 @@
+{
+  "version": 3,
+  "targets": {
+    "net6.0": {}
+  },
+  "libraries": {},
+  "projectFileDependencyGroups": {
+    "net6.0": []
+  },
+  "packageFolders": {
+    "C:\\Users\\User\\.nuget\\packages\\": {},
+    "C:\\Program Files (x86)\\Microsoft Visual Studio\\Shared\\NuGetPackages": {}
+  },
+  "project": {
+    "version": "1.0.0",
+    "restore": {
+      "projectUniqueName": "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\AntonovLab9.csproj",
+      "projectName": "AntonovLab9",
+      "projectPath": "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\AntonovLab9.csproj",
+      "packagesPath": "C:\\Users\\User\\.nuget\\packages\\",
+      "outputPath": "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\obj\\",
+      "projectStyle": "PackageReference",
+      "fallbackFolders": [
+        "C:\\Program Files (x86)\\Microsoft Visual Studio\\Shared\\NuGetPackages"
+      ],
+      "configFilePaths": [
+        "C:\\Users\\User\\AppData\\Roaming\\NuGet\\NuGet.Config",
+        "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.FallbackLocation.config",
+        "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
+      ],
+      "originalTargetFrameworks": [
+        "net6.0"
+      ],
+      "sources": {
+        "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
+        "https://api.nuget.org/v3/index.json": {}
+      },
+      "frameworks": {
+        "net6.0": {
+          "targetAlias": "net6.0",
+          "projectReferences": {}
+        }
+      },
+      "warningProperties": {
+        "warnAsError": [
+          "NU1605"
+        ]
+      }
+    },
+    "frameworks": {
+      "net6.0": {
+        "targetAlias": "net6.0",
+        "imports": [
+          "net461",
+          "net462",
+          "net47",
+          "net471",
+          "net472",
+          "net48",
+          "net481"
+        ],
+        "assetTargetFallback": true,
+        "warn": true,
+        "frameworkReferences": {
+          "Microsoft.NETCore.App": {
+            "privateAssets": "all"
+          }
+        },
+        "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.401\\RuntimeIdentifierGraph.json"
+      }
+    }
+  }
+}

+ 8 - 0
AntonovLab9/obj/project.nuget.cache

@@ -0,0 +1,8 @@
+{
+  "version": 2,
+  "dgSpecHash": "Sr4zYUIZEAG9VjpXClkgX7WW+hasrrESyvFtgvqh0l+1dKX7t4tYCMt7R17EjQAhs7aSLPMByxNkB+oA0DIDdQ==",
+  "success": true,
+  "projectFilePath": "C:\\Users\\User\\Source\\Repos\\AntonovLab9\\AntonovLab9\\AntonovLab9.csproj",
+  "expectedPackageFiles": [],
+  "logs": []
+}