Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace Administrirovanie_Kafe
- {
- class Program
- {
- static void Main(string[] args)
- {
- Player player = new Player("Никита", "Россия", 23);
- player.ShowInfo();
- }
- }
- class Player
- {
- private string _name;
- private string _country;
- private int _age;
- public Player(string name, string country, int age)
- {
- _name = name;
- _country = country;
- _age = age;
- }
- public void ShowInfo()
- {
- Console.WriteLine($"Имя игрока - {_name}, страна игрока - {_country}, возраст игрока - {_age}");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement