From 7b607f208e56964530bd7d18ba28e27849508cbb Mon Sep 17 00:00:00 2001 From: 328p <328p@BTK.MAIN> Date: Wed, 7 Oct 2026 14:18:00 +0300 Subject: [PATCH] =?UTF-8?q?=D0=BD=D0=B0=D1=87=D0=B0=D0=BB=20lesson6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- works/lab-06/lesson6/lesson6.sln | 16 ++++++ works/lab-06/lesson6/lesson6/Program.cs | 56 +++++++++++++++++++++ works/lab-06/lesson6/lesson6/lesson6.csproj | 10 ++++ 3 files changed, 82 insertions(+) create mode 100644 works/lab-06/lesson6/lesson6.sln create mode 100644 works/lab-06/lesson6/lesson6/Program.cs create mode 100644 works/lab-06/lesson6/lesson6/lesson6.csproj diff --git a/works/lab-06/lesson6/lesson6.sln b/works/lab-06/lesson6/lesson6.sln new file mode 100644 index 0000000..af2dc05 --- /dev/null +++ b/works/lab-06/lesson6/lesson6.sln @@ -0,0 +1,16 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "lesson6", "lesson6\lesson6.csproj", "{4FEDC623-0924-41BC-98BE-C2A83D856398}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4FEDC623-0924-41BC-98BE-C2A83D856398}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {4FEDC623-0924-41BC-98BE-C2A83D856398}.Debug|Any CPU.Build.0 = Debug|Any CPU + {4FEDC623-0924-41BC-98BE-C2A83D856398}.Release|Any CPU.ActiveCfg = Release|Any CPU + {4FEDC623-0924-41BC-98BE-C2A83D856398}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection +EndGlobal diff --git a/works/lab-06/lesson6/lesson6/Program.cs b/works/lab-06/lesson6/lesson6/Program.cs new file mode 100644 index 0000000..06911d8 --- /dev/null +++ b/works/lab-06/lesson6/lesson6/Program.cs @@ -0,0 +1,56 @@ +class Pokemon +{ + private string name; + private int level; + private int hp; + + public string Name + { + get { return name;} + set {} + + + } + public int Level + { + get { return level;} + set {} + + + } + public int HP + { + get { return hp;} + set {} + } + + public Pokemon(string name, int level, int hp) + { + Name = name; + Level = level; + HP = hp; + } + + public void ShowInfo() + { + Console.Write($"Имя: {Name}, Уровень: {Level}, HP: {HP}"); + + } + + static void Main() + { + var Picachu = new Pokemon("Пикачу", 5, 100); + var Scvirl = new Pokemon("Сквиртл", 7, 90); + Console.WriteLine("=== ПОКЕДЕКС ==="); + Console.Write("1. "); + Picachu.ShowInfo(); + Console.Write("2. "); + Scvirl.ShowInfo(); + + + + + + } + +} \ No newline at end of file diff --git a/works/lab-06/lesson6/lesson6/lesson6.csproj b/works/lab-06/lesson6/lesson6/lesson6.csproj new file mode 100644 index 0000000..6c1dc92 --- /dev/null +++ b/works/lab-06/lesson6/lesson6/lesson6.csproj @@ -0,0 +1,10 @@ + + + + Exe + net10.0 + enable + enable + + +