Skip to content

Instantly share code, notes, and snippets.

View RPVUnityDeveloper's full-sized avatar

RPV RPVUnityDeveloper

View GitHub Profile
@RPVUnityDeveloper
RPVUnityDeveloper / gist:1a304635a2612c8a3867f217c6d8da15
Last active November 3, 2025 18:46
Объединение в одну коллекцию
using System;
using System.Collections.Generic;
class Program
{
static void Main()
{
string[] array1 = { "1", "2", "1" };
string[] array2 = { "3", "2" };
@RPVUnityDeveloper
RPVUnityDeveloper / gist:04ffb60d02ad356cc162b62c2760378d
Last active November 3, 2025 17:51
Кадровый учет продвинутый
using System;
using System.Collections.Generic;
class Program
{
static void Main()
{
const string CommandAddWorker = "1";
const string CommandRemoveWorker = "2";
const string CommandShowAllPositionsAndWorkers = "3";
@RPVUnityDeveloper
RPVUnityDeveloper / gist:c37e041c22d061a158f51cf11b7f42b9
Last active November 3, 2025 16:48
Динамический массив продвинутый
using System;
using System.Collections.Generic;
class Program
{
static void Main()
{
const string CommandSum = "sum";
const string CommandExit = "exit";
@RPVUnityDeveloper
RPVUnityDeveloper / gist:86cf870602c504b571edee1ad072db45
Last active November 3, 2025 17:46
Динамический массив
using System;
class Program
{
static void Main()
{
const string CommandSum = "sum";
const string CommandExit = "exit";
int[] numbers = new int[0];
@RPVUnityDeveloper
RPVUnityDeveloper / gist:f4715faeadc36d50b84c079b2fe99641
Created November 3, 2025 11:43
Очередь в магазине
using System;
using System.Collections;
using System.Collections.Generic;
class Program
{
static void Main()
{
Queue<int> customerQueue = new Queue<int>(new int[] { 50, 120, 30, 200, 75 });
@RPVUnityDeveloper
RPVUnityDeveloper / gist:fcb2e0a917ce77e52e576e641df05ad6
Created November 3, 2025 11:36
Толковый словарь
using System;
using System.Collections.Generic;
class Program
{
static void Main()
{
Dictionary<string, string> dictionary = new Dictionary<string, string>
{
{ "Яблоко", "Фрукт, который растет на деревьях." },
class Program
{
static void Main()
{
char[,] map =
{
{ '#','#','#','#','#','#','#','#','#','#' },
{ '#',' ',' ',' ',' ',' ',' ',' ',' ','#' },
{ '#',' ','#','#','#',' ','#','#',' ','#' },
{ '#',' ','#',' ','#',' ','#',' ',' ','#' },
class Program
{
static void Main()
{
const string CommandAddDossier = "1";
const string CommandBringOutAllDossiers = "2";
const string CommandRemoveDossier = "3";
const string CommandSearchByLastName = "4";
const string CommanExit = "5";
@RPVUnityDeveloper
RPVUnityDeveloper / gist:de7939f5b18a478a82c6798fb4423cbe
Created November 3, 2025 09:28
Канзас сити шафл
class Program
{
static void Main()
{
int[] numbers = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 };
Console.WriteLine("Исходный массив:");
foreach (int number in numbers)
{
class Program
{
static void Main()
{
int maxHealth = 100;
int currentHealth = 65;
int maxMana = 50;
int currentMana = 20;
int barLength = 20;