using System;
using System.IO;
using System.Text;
using System.Collections;
using System.Collections.Generic;

public class B
{
    public partial class Myon
    {
        //static void Main()
        //{
        //    B p = new B();
        //    p.solve();
        //}
    }

    public void solve()
    {
        string[] tmp = stringSplit(' ');
        string aa = tmp[0];
        string b = tmp[1];

        int a = int.Parse(aa);
        for (a++; ; a++)
        {
            if (ok(a, b))
            {
                Console.WriteLine(a);
                break;
            }
        }
    }

    bool ok(int a, string b)
    {
        for (int i = b.Length - 1; i >= 0; i--)
        {
            while (a % 10 != b[i] - '0')
            {
                if (a == 0)
                    return false;
                a /= 10;
            }
            a /= 10;
        }//forrev i
        return true;
    }

    string stringRead()
    { return Console.ReadLine(); }

    int intRead()
    { return int.Parse(Console.ReadLine()); }

    long longRead()
    { return long.Parse(Console.ReadLine()); }

    string[] stringSplit(char a)
    { return Console.ReadLine().Split(a); }

    int[] intSplit(char a)
    { return Array.ConvertAll<string, int>(Console.ReadLine().Split(a), int.Parse); }

    long[] longSplit(char a)
    { return Array.ConvertAll<string, long>(Console.ReadLine().Split(a), long.Parse); }

    void write(string str)
    {
        Console.WriteLine(str);
    }
}


using System; using System.Linq;

class P {
  static void Main() {
    var s =  Console.ReadLine().Split(' ').Select(int.Parse).ToArray();
    var a = s[0]; var b = s[1];
    do {
      a++;
      var tmp = a; var m = 1; var mask = 0;
      while (tmp > 0) {
        if (tmp % 10 == 4 || tmp % 10 == 7) { mask += m * (tmp % 10); m*=10; }
        tmp /= 10;
      }
      if (mask == b) { Console.Write(a); return; }
    }
  }
}


class MainClass
    {
        public static void Main(string[] args)
        {
            var fl = Console.ReadLine().Split(' ').Select(i => int.Parse(i)).ToArray();
            var sl = Console.ReadLine().Split(' ').Select(i => int.Parse(i)).ToArray();

            int n = fl[0] - 1;
            int k = fl[1];
            int x = fl[2];

            int sum = 0;
            for (var i = n; i > -1; i--){
                if (n - i < k){
                    continue;
                }

                sum += sl[i];
            }

            Console.WriteLine(sum + k * x);
        }
    }


        int n = int.Parse(Console.ReadLine());
        int count = 0;

        while (n != 0)
        {
            count += n / 100;
            n = n % 100;
            count += n / 20;
            n = n % 20;
            count += n / 5;
            n = n % 5;
            count += n / 2;
            n = n % 2;
            count += n / 1;
            n = n % 1;
        }
        Console.WriteLine(count);


#include <bits/stdc++.h>
using namespace std;

int main()
{
    int num,c=0,t;
    cin>>num;
    if(num%100 != 0)
    {
        c += (num/100);
        num%=100;
        if(num%20 == 0)
        {
            cout<<num/20 + c;
        }
        else
        {
            c+= num/20;
            num%=20;
            if(num%10 == 0)
            {
                cout<<c + num/10;
            }
            else
            {
                c += num/10;
                num%=10;
                if(num%5 == 0)
                {
                    cout<<c + num/5;
                }
                else
                {
                    c += num/5;
                    num%=5;
                    cout<<c+num;
                }
            }
        }

    }
    else if(num >= 100)
    {
        cout<<num/100;
    }
    return 0;
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Allen
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] numbers = Console.ReadLine().Split().Select(x => int.Parse(x)).ToArray();
            int quantityOFcash = 0;
            while(numbers[0] - 100 >= 0)
            {
                if (numbers[0] - 100 >= 0)
                {
                    quantityOFcash++;
                    numbers[0] -= 100;
                }
            }
            while (numbers[0] - 20 >= 0)
            {
                if (numbers[0] - 20 >= 0)
                {
                    quantityOFcash++;
                    numbers[0] -= 20;
                }
            }
            while (numbers[0] - 10 >= 0)
            {
                if (numbers[0] - 10 >= 0)
                {
                    quantityOFcash++;
                    numbers[0] -= 10;
                }
            }
            while (numbers[0] - 5 >= 0)
            {
                if (numbers[0] - 5 >= 0)
                {
                    quantityOFcash++;
                    numbers[0] -= 5;
                }
            }
            while (numbers[0] - 1 >= 0)
            {
                if (numbers[0] - 1 >= 0)
                {
                    quantityOFcash++;
                    numbers[0] -= 1;
                }
            }
            Console.WriteLine(quantityOFcash);
        }


using System;
using System.Collections.Generic;
using System.Data.SqlTypes;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            int number = Convert.ToInt32(Console.ReadLine());
            int result  = 0;

            while(number != 0)
            {
                if (number >= 100)
                {
                    number -= 100;
                    result++;
                }
                else if (number >= 20)
                {
                    number -= 20;
                    result++;
                }
                else if(number >= 10)
                {
                    number -= 10;
                    result++;
                }
                else if (number >= 5)
                {
                    number -= 5;
                    result++;
                }
                else if (number >= 1)
                {
                    number -= 1;
                    result++;
                }
            }

            Console.WriteLine(result);
        }
    }
}


Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.28307.1062
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleApp7", "ConsoleApp7.csproj", "{0BE878F0-59C5-4937-97E2-067D4DE3BF00}"
EndProject
Global
	GlobalSection(SolutionConfigurationPlatforms) = preSolution
		Debug|Any CPU = Debug|Any CPU
		Release|Any CPU = Release|Any CPU
	EndGlobalSection
	GlobalSection(ProjectConfigurationPlatforms) = postSolution
		{0BE878F0-59C5-4937-97E2-067D4DE3BF00}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{0BE878F0-59C5-4937-97E2-067D4DE3BF00}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{0BE878F0-59C5-4937-97E2-067D4DE3BF00}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{0BE878F0-59C5-4937-97E2-067D4DE3BF00}.Release|Any CPU.Build.0 = Release|Any CPU
	EndGlobalSection
	GlobalSection(SolutionProperties) = preSolution
		HideSolutionNode = FALSE
	EndGlobalSection
	GlobalSection(ExtensibilityGlobals) = postSolution
		SolutionGuid = {33B23004-8358-49E5-B718-E34496A6C7BA}
	EndGlobalSection
EndGlobal


using System;
using System.Linq;
using System.Reflection.PortableExecutable;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            int Cant = 0;
            int Money = Int32.Parse(Console.ReadLine());
            int[] Monedas = { 100, 20, 10, 5, 1 };

            for (int i = 0; i < Monedas.Length;i++)
            {
                if (Money == 0)
                {
                    break;
                }

                while (Money / Monedas[i] > 0)
                {
                    Money -= Monedas[i];
                    Cant++;
                }
            }

            Console.WriteLine(Cant);

        }

    }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Numerics;

using System.Text.RegularExpressions;

class Program
{
    static public int[] readIntArray()
    {
        return (from string s in Console.ReadLine().Split(' ') select Convert.ToInt32(s)).ToArray();
    }
    static public long[] readLongArray()
    {
        return (from string s in Console.ReadLine().Split(' ') select Convert.ToInt64(s)).ToArray();
    }
    static public ulong[] readULongArray()
    {
        return (from string s in Console.ReadLine().Split(' ') select Convert.ToUInt64(s)).ToArray();
    }
    public static int readInt()
    {
        return Convert.ToInt32(Console.ReadLine());
    }

    static void Main(string[] args)
    {

        RountineProblem();
    }
    static void RountineProblem()
    {
        int[] arr = readIntArray();
        int bc = arr[1] * arr[2];
        int ad = arr[0] * arr[3];
        int up = 0;
        int down = 0;
        if (bc > ad)
        {
            up = bc - ad;
            down = bc;
        }
        else
        {
            up = ad - bc;
            down = ad;
        }
        int gcd = (int)BigInteger.GreatestCommonDivisor(up, down);
        up /= gcd;
        down /= gcd;
        if (up == 0) { down = 1; }
        Console.WriteLine("{0}/{1}",up,down);

    }

}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp2
{
    public class RandomMath
    {
        static void Main(string[] args)
        {
            public static void WhatAmIDoing(int n)
            {
                int n = = int.Parse(Console.ReadLine());
                List<int> Solutions = new List<int>();
                int HowMuch = 0;
                int CheckThis;
                int[] Digits;
                CheckThis = n <= 81 ? 0 : n - 81;
                for (int x = CheckThis; x < n; x++)
                {
                    Digits = x.ToString().Select(t => int.Parse(t.ToString())).ToArray();
                    int DigitsValue = 0;
                    foreach (int dig in Digits)
                    {
                        DigitsValue += dig;
                    }
                    if (x + DigitsValue == n)
                    {
                        HowMuch += 1;
                        Solutions.Add(x);

                    }
                }
                Console.WriteLine(HowMuch);
                foreach(int Solution in Solutions)
                {
                    Console.WriteLine(Solution);
                }
            }
        }
    }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp2
{
    public class RandomMath
    {
        public static void WhatAmIDoing(int n)
        {
            int n ==  int.Parse(Console.ReadLine());
            List<int> Solutions = new List<int>();
            int HowMuch = 0;
            int CheckThis;
            int[] Digits;
            CheckThis = n <= 81 ? 0 : n - 81;
            for (int x = CheckThis; x < n; x++)
            {
                Digits = x.ToString().Select(t => int.Parse(t.ToString())).ToArray();
                int DigitsValue = 0;
                foreach (int dig in Digits)
                {
                    DigitsValue += dig;
                }
                if (x + DigitsValue == n)
                {
                    HowMuch += 1;
                    Solutions.Add(x);

                }
            }
            Console.WriteLine(HowMuch);
            foreach(int Solution in Solutions)
            {
                Console.WriteLine(Solution);
            }
        }

    }
}


using System;
using System.Collections;
using System.Collections.Generics;
using System.Linq;

namespace Problem{

    public class Solution{

        public void Main(){

            int n = int.Parse(Console.ReadLine());
             if(n == 1){
                 Console.WriteLine(n);
             }else{
                 Console.WriteLine((n*2 - 3)*(n*2 - 3) + 4));
             }
        }
    }
}


using System;
using System.Collections.Generic;
using System.Text;

namespace ConsoleApp12
{
    class Solution
    {
        static int Compute(int n)
        {
            int last = n * 2 - 1;
            return (1 + last) * n - last;
        }
    }
}


using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;

namespace Problem{

    public class Solution{

        public void Main(){

            int n = int.Parse(Console.ReadLine());
             if(n == 1){
                 Console.WriteLine(n);
             }else{
                 Console.WriteLine((n*2 - 3)*(n*2 - 3) + 4);
             }
        }
    }
}


static void Main(string[] args)
        {
            Console.Write("n: ");
            int n = int.Parse(Console.ReadLine());
            Console.Write("k: ");
            int k = int.Parse(Console.ReadLine());
            Console.WriteLine(Func(n, k));
        }
        static int Func(int n, int k)
        {
            int cnt1 = 0, cnt2 = 0;
            while (n > 0 && cnt2 < k)
            {
                cnt1++;
                if (n % 10 == 0)
                    cnt2++;
                n /= 10;
            }
            if (cnt2 < k)
                return cnt1 - 1;
            return cnt1 - cnt2;
        }


using System;

class Program {
  static void Main() {
    var n = int.Parse(Console.ReadLine());
    if (n < 3) Console.WriteLine(-1);
    else Console.Write(string.Join(" ", (new [] {2,3,1}).Concat(Enumerable.Range(4, 4 - n)));
  }
}


using System;

class Program {
  static void Main() {
    var n = int.Parse(Console.ReadLine());
    if (n < 3) Console.WriteLine(-1);
    else Console.Write(string.Join(" ", (new [] {2,3,1}).Concat(Enumerable.Range(4, 4 - n))));
  }
}


using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Text;

namespace AprilFools
{
    internal class Program
    {
        private const string TestIn = @"..\..\In\Text.in";
        private const string TestOut = @"..\..\In\Text.out";

        private static void Solve()
        {
            var num = ReadInt();
            if (num < 3) Console.WriteLine(-1);
            else Console.WriteLine(string.Join(" ",  Enumerable.Range(1,num).Reverse().ToArray()));
        }

        private static void Main()
        {
            if (Debugger.IsAttached)
            {
                Console.SetIn(new StreamReader(TestIn));
                Console.SetOut(new StreamWriter(TestOut));
            }

            Solve();

            if (Debugger.IsAttached)
            {
                Console.In.Close();
                Console.Out.Close();
                Console.SetIn(new StreamReader(Console.OpenStandardInput()));
                //Console.ReadLine();
            }
        }

        #region Reader

        private static string Read()
        {
            return Console.ReadLine();
        }

        private static string[] ReadArray()
        {
            return Console.ReadLine().Split(' ');
        }

        private static List<int> ReadIntArray()
        {
            var input = Console.ReadLine().Split(' ').Select(Int32.Parse).ToList();
            return input;
        }

        private static int ReadInt()
        {
            return Int32.Parse(Console.ReadLine());
        }

        private static long ReadLong()
        {
            return long.Parse(Console.ReadLine());
        }

        private static int ReadNextInt(string[] input, int index)
        {
            return Int32.Parse(input[index]);
        }

        #endregion
    }
}


using System;

class Program
{
    public static void Main(string[] args)()
    {
        int n = int.Parse(Console.ReadLine());
        if(n < 3)
            Console.WriteLine(-1);
        else
            for(int i = n; i > 0; i--)
                Console.Write(i + " ");
    }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace timus1100
{
    class Program
    {

        static void Main(string[] args)
        {
            int n, k;
            string i = "";
            string[] numbers = Console.ReadLine().Split(' ');
            n = int.Parse(numbers[0]);
            k = int.Parse(numbers[1]);

            var source = new[] { Console.ReadLine() };

            var result = source.Select(s => new string(s.OrderBy(ch => ch).ToArray()));

            byte bytes = Encoding.ASCII.GetBytes("a");
            foreach (string s in result) i = String.Concat(i, s);
            char last = Convert.ToChar(bytes - 2);
            int ans = 0;
            int len = 0;
            for (int ik = 0; ik < n; ik++)

                if (i[ik] >= last + 2)
                {
                    last = i[ik];
                    ans += i[ik] - 'a' + 1;
                    len++;
                    if (len == k)
                    {
                        Console.WriteLine(ans);
                        //Console.ReadKey();
                        Environment.Exit(0);

                    }
                }
            Console.WriteLine("-1");

            //  Console.ReadKey();

        }
    }
}


 class Program
    {
        static void Main(string[] args)
        {
            //int intTemp = Convert.ToInt32(Console.ReadLine());
            string[] input = Console.ReadLine().Split(' ');
            string str = Console.ReadLine();
            int noStage = Convert.ToInt32(input[0]);
            int useStage = Convert.ToInt32(input[1]);
            List<char> strarr = str.ToList();
            if (useStage > strarr.Count)
            {
                Console.WriteLine(-1);
                return;
            }
            strarr.Sort();
            for (int i = 0;i<strarr.Count-1;i++ )
            {
                if ((int)strarr[i + 1] - (int)strarr[i] == 0 || (int)strarr[i + 1] - (int)strarr[i] == 1) {
                    strarr.RemoveAt(i+1);
                }
            }
            if (useStage > strarr.Count)
            {
                Console.WriteLine(-1);
            }
            else {
                Console.WriteLine(strarr.Take(useStage).Sum(c=>(int)c-96));
            }

            Console.ReadLine();

        }
    }


 class Program
    {
        static void Main(string[] args)
        {
            //int intTemp = Convert.ToInt32(Console.ReadLine());
            string[] input = Console.ReadLine().Split(' ');
            string str = Console.ReadLine();
            int noStage = Convert.ToInt32(input[0]);
            int useStage = Convert.ToInt32(input[1]);
            List<char> strarr = str.ToList();
            if (useStage > strarr.Count)
            {
                Console.WriteLine(-1);
                return;
            }
            strarr.Sort();
            for (int i = 0;i<strarr.Count-1;i++ )
            {
                if ((int)strarr[i + 1] - (int)strarr[i] == 0 || (int)strarr[i + 1] - (int)strarr[i] == 1) {
                    strarr.RemoveAt(i+1);
                }
            }
            if (useStage > strarr.Count)
            {
                Console.WriteLine(-1);
            }
            else {
                Console.WriteLine(strarr.Take(useStage).Sum(c=>(int)c-96));
            }

        }
    }


<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectGuid>{6E9044DB-BA15-4CBE-AC2A-7ABAA7C39024}</ProjectGuid>
    <OutputType>Exe</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>FiljaISonja</RootNamespace>
    <AssemblyName>FiljaISonja</AssemblyName>
    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
    <FileAlignment>512</FileAlignment>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release\</OutputPath>
    <DefineConstants>TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="System.Core" />
    <Reference Include="System.Xml.Linq" />
    <Reference Include="System.Data.DataSetExtensions" />
    <Reference Include="Microsoft.CSharp" />
    <Reference Include="System.Data" />
    <Reference Include="System.Xml" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Program.cs" />
    <Compile Include="Properties\AssemblyInfo.cs" />
  </ItemGroup>
  <ItemGroup>
    <None Include="App.config" />
  </ItemGroup>
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
       Other similar extension points exist, see Microsoft.Common.targets.
  <Target Name="BeforeBuild">
  </Target>
  <Target Name="AfterBuild">
  </Target>
  -->
</Project>


<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectGuid>{2EAAF829-089B-443C-A985-B1AB48407DE9}</ProjectGuid>
    <OutputType>Exe</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>Task_01</RootNamespace>
    <AssemblyName>Task_01</AssemblyName>
    <TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
    <FileAlignment>512</FileAlignment>
    <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release\</OutputPath>
    <DefineConstants>TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="System.Core" />
    <Reference Include="System.Xml.Linq" />
    <Reference Include="System.Data.DataSetExtensions" />
    <Reference Include="Microsoft.CSharp" />
    <Reference Include="System.Data" />
    <Reference Include="System.Net.Http" />
    <Reference Include="System.Xml" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Program.cs" />
    <Compile Include="Properties\AssemblyInfo.cs" />
  </ItemGroup>
  <ItemGroup>
    <None Include="App.config" />
  </ItemGroup>
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
       Other similar extension points exist, see Microsoft.Common.targets.
  <Target Name="BeforeBuild">
  </Target>
  <Target Name="AfterBuild">
  </Target>
  -->
</Project>


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _224A.Parallelepiped
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] ars = Console.ReadLine().Split().Select(int.Parse).ToArray();
            Console.WriteLine(counters(ars));

        }
        static int counters(int[]ars)
        {

            double x= ars[0] * ars[2] / ars[1];
            double y= ars[0] * ars[1] / ars[2];
            double z= ars[1] * ars[2] / ars[0];
            int a=0, b=0, c=0;
            int[] roots = new int[101];
            for (int i = 0; i < roots.Length; i++)
            {
                roots[i] = (i) * (i);
            }
            int j = 1;
            while(x>=roots[j]|| y >= roots[j]|| z >= roots[j])
            {
                if (x <= roots[j] && x > roots[j - 1])
                {
                    x = roots[j];
                    a = j;
                }
                if (y <= roots[j] && y > roots[j - 1])
                {
                    y = roots[j];
                    b = j;
                }
                if (z <= roots[j] && z > roots[j - 1])
                {
                    z = roots[j];
                    c = j;
                }
                j++;
            }
            return 4*(a + b + c);
        }
    }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = System.ValueTuple<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var a = new[] { 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 1, 1 };
        var s = RLEncoding(a);

    }

    public List<(T item, int len)> RLEncoding<T>(IList<T> list, Comparison<T> cmp = null)
    {
        cmp = cmp ?? Comparer<T>.Default.Compare;
        var rt = new List<(T, int)> { (list[0], 1) };
        for (var i = 1; i < list.Count; i++)
            if (cmp(rt[1].Item1, list[i]) == 0)
                rt[1] = (rt[1].Item1, rt[1].Item2 + 1);
            else rt.Add((list[i], 1));
        return rt;
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    //public static int PopCount(int n) => (int)System.Runtime.Intrinsics.X86.Popcnt.PopCount((uint)n);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    //public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ').AsSpan()[..]) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
    public (T1, T2) Make<T1, T2>() { (T1, T2) rt=(default,default); Make(out rt.Item1, out rt.Item2); return rt; }
    public (T1, T2, T3) Make<T1, T2, T3>() { (T1, T2, T3) rt=(default,default,default); Make(out rt.Item1, out rt.Item2, out rt.Item3); return rt; }
    public (T1, T2, T3, T4) Make<T1, T2, T3, T4>() { (T1, T2, T3, T4) rt=(default,default,default,default); Make(out rt.Item1, out rt.Item2, out rt.Item3, out rt.Item4); return rt; }
}

#endregion


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = System.ValueTuple<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var a = new[] { 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 1, 1 };
        //var s = RLEncoding(a);

    }

    /*public List<(T item, int len)> RLEncoding<T>(IList<T> list, Comparison<T> cmp = null)
    {
        cmp = cmp ?? Comparer<T>.Default.Compare;
        var rt = new List<(T, int)> { (list[0], 1) };
        for (var i = 1; i < list.Count; i++)
            if (cmp(rt[1].Item1, list[i]) == 0)
                rt[1] = (rt[1].Item1, rt[1].Item2 + 1);
            else rt.Add((list[i], 1));
        return rt;
    }*/
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    //public static int PopCount(int n) => (int)System.Runtime.Intrinsics.X86.Popcnt.PopCount((uint)n);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    //public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ').AsSpan()[..]) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
    public (T1, T2) Make<T1, T2>() { (T1, T2) rt; Make(out rt.Item1, out rt.Item2); return rt; }
    public (T1, T2, T3) Make<T1, T2, T3>() { (T1, T2, T3) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3); return rt; }
    public (T1, T2, T3, T4) Make<T1, T2, T3, T4>() { (T1, T2, T3, T4) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3, out rt.Item4); return rt; }
}

#endregion


#include<bits/stdc++.h>

using namespace std;

int main()
{
    int i,n;
    int str;
    cin >> n >> str;
    cout << n+1 << endl;
    return 0;
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = System.ValueTuple<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var a = new[] { 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 1, 1 };
        var s = RLEncoding(a);

    }

    public List<(T item, int len)> RLEncoding<T>(IList<T> list, Comparison<T> cmp = null)
    {
        cmp = cmp??Comparer<T>.Default.Compare;
        var rt = new List<(T, int)> { (list[0], 1) };
        for (var i = 1; i < list.Count; i++)
            if (cmp(rt[1].Item1, list[i]) == 0)
                rt[1] = (rt[1].Item1, rt[1].Item2 + 1);
            else rt.Add((list[i], 1));
        return rt;
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    //public static int PopCount(int n) => (int)System.Runtime.Intrinsics.X86.Popcnt.PopCount((uint)n);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    //public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ').AsSpan()[..]) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
    public (T1, T2) Make<T1, T2>() { (T1, T2) rt; Make(out rt.Item1, out rt.Item2); return rt; }
    public (T1, T2, T3) Make<T1, T2, T3>() { (T1, T2, T3) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3); return rt; }
    public (T1, T2, T3, T4) Make<T1, T2, T3, T4>() { (T1, T2, T3, T4) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3, out rt.Item4); return rt; }
}

#endregion


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = System.ValueTuple<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var a = new[] { 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 1, 1 };
        var s = RLEncoding(a);

    }

    public List<(T item, int len)> RLEncoding<T>(IList<T> list, Comparison<T> cmp = null)
    {
        cmp = cmp ?? Comparer<T>.Default.Compare;
        var rt = new List<(T, int)> { (list[0], 1) };
        for (var i = 1; i < list.Count; i++)
            if (cmp(rt[1].Item1, list[i]) == 0)
                rt[1] = (rt[1].Item1, rt[1].Item2 + 1);
            else rt.Add((list[i], 1));
        return rt;
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    //public static int PopCount(int n) => (int)System.Runtime.Intrinsics.X86.Popcnt.PopCount((uint)n);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    //public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ').AsSpan()[..]) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
}

#endregion


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = System.ValueTuple<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var (N, s) = (sc.Int, sc.Str);
        WriteLine(N + 1);
    }

    public List<(T item, int len)> RLEncoding<T>(IList<T> list, Comparison<T> cmp = null)
    {
        cmp = cmp ?? Comparer<T>.Default.Compare;
        var rt = new List<(T, int)> { (list[0], 1) };
        for (var i = 1; i < list.Count; i++)
            if (cmp(rt[^1].Item1, list[i]) == 0)
                rt[1] = (rt[1].Item1, rt[1].Item2 + 1);
            else rt.Add((list[i], 1));
        return rt;
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    //public static int PopCount(int n) => (int)System.Runtime.Intrinsics.X86.Popcnt.PopCount((uint)n);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    //public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ').AsSpan()[..]) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
}

#endregion


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = System.ValueTuple<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var a = new[] { 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 1, 1 };
        var s = RLEncoding(a);

    }

    public List<(T item, int len)> RLEncoding<T>(IList<T> list, Comparison<T> cmp = null)
    {
        cmp ??= Comparer<T>.Default.Compare;
        var rt = new List<(T, int)> { (list[0], 1) };
        for (var i = 1; i < list.Count; i++)
            if (cmp(rt[^1].Item1, list[i]) == 0)
                rt[^1] = (rt[^1].Item1, rt[^1].Item2 + 1);
            else rt.Add((list[i], 1));
        return rt;
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    //public static int PopCount(int n) => (int)System.Runtime.Intrinsics.X86.Popcnt.PopCount((uint)n);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    //public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ').AsSpan()[..]) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
    public (T1, T2) Make<T1, T2>() { (T1, T2) rt; Make(out rt.Item1, out rt.Item2); return rt; }
    public (T1, T2, T3) Make<T1, T2, T3>() { (T1, T2, T3) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3); return rt; }
    public (T1, T2, T3, T4) Make<T1, T2, T3, T4>() { (T1, T2, T3, T4) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3, out rt.Item4); return rt; }
}

#endregion


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = Pair<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var a=new[]{1,2,3};
        var b=a[^1];
        (int N, string s) p;
        sc.Make(out p.N, out p.s);
        WriteLine(p.N+1);
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T>
    { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T>
    { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b)
    { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Copy<T>(this T[] A) => Create(A.Length, i => A[i]);
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static Pair<T, U> MP<T, U>(T t, U u) => new Pair<T, U>(t, u);
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static Pair<T, U, V> MP<T, U, V>(T t, U u, V v) => new Pair<T, U, V>(t, u, v);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    public Pair<T1, T2> MP<T1, T2>() => new Pair<T1, T2>(Next<T1>(), Next<T2>());
    public Pair<T1, T2, T3> MP<T1, T2, T3>() => new Pair<T1, T2, T3>(Next<T1>(), Next<T2>(), Next<T3>());
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
}

public class Pair<T1, T2> : IComparable<Pair<T1, T2>>
{
    public T1 v1;
    public T2 v2;
    public Pair() { }
    public Pair(T1 v1, T2 v2)
    { this.v1 = v1; this.v2 = v2; }

    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public int CompareTo(Pair<T1, T2> p)
    {
        var c = Comparer<T1>.Default.Compare(v1, p.v1);
        if (c == 0)
            c = Comparer<T2>.Default.Compare(v2, p.v2);
        return c;
    }
    public override string ToString() => $"{v1.ToString()} {v2.ToString()}";
    public void Tie(out T1 a, out T2 b) { a = v1; b = v2; }
}

public class Pair<T1, T2, T3> : Pair<T1, T2>, IComparable<Pair<T1, T2, T3>>
{
    public T3 v3;
    public Pair() : base() { }
    public Pair(T1 v1, T2 v2, T3 v3) : base(v1, v2)
    { this.v3 = v3; }

    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public int CompareTo(Pair<T1, T2, T3> p)
    {
        var c = base.CompareTo(p);
        if (c == 0)
            c = Comparer<T3>.Default.Compare(v3, p.v3);
        return c;
    }
    public override string ToString() => $"{base.ToString()} {v3.ToString()}";
    public void Tie(out T1 a, out T2 b, out T3 c) { Tie(out a, out b); c = v3; }
}
#endregion


using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Runtime.CompilerServices;
using System.Text;
using System.Numerics;
using static Template;
using static System.Console;
using static System.Convert;
using static System.Math;
using Pi = System.ValueTuple<int, int>;

class Solver
{
    public void Solve(Scanner sc)
    {
        var a = new[] { 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 1, 1 };
        var s = RLEncoding(a);

    }

    public List<(T item, int len)> RLEncoding<T>(IList<T> list, Comparison<T> cmp = null)
    {
        cmp ??= Comparer<T>.Default.Compare;
        var rt = new List<(T, int)> { (list[0], 1) };
        for (var i = 1; i < list.Count; i++)
            if (cmp(rt[1].Item1, list[i]) == 0)
                rt[1] = (rt[1].Item1, rt[1].Item2 + 1);
            else rt.Add((list[i], 1));
        return rt;
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    //public static int PopCount(int n) => (int)System.Runtime.Intrinsics.X86.Popcnt.PopCount((uint)n);
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}

public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    //public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ').AsSpan()[..]) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
    public (T1, T2) Make<T1, T2>() { (T1, T2) rt; Make(out rt.Item1, out rt.Item2); return rt; }
    public (T1, T2, T3) Make<T1, T2, T3>() { (T1, T2, T3) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3); return rt; }
    public (T1, T2, T3, T4) Make<T1, T2, T3, T4>() { (T1, T2, T3, T4) rt; Make(out rt.Item1, out rt.Item2, out rt.Item3, out rt.Item4); return rt; }
}

#endregion


using System;
using System.Collections.Generic;

namespace olymp
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] input = Console.ReadLine().Split();
            int n = Int32.Parse(input[0]);
            int limit = Int32.Parse(input[1]);

            string[] time = Console.ReadLine().Split();
            int[] needToLeave = new int[n];
            List<int> orderedTime = new List<int>();
            int accumulator = 0;
            int thisTime = 0;
            int j = 0;
            for(int i = 0; i < n; i++)
            {
                thisTime = Int32.Parse(time[i]);
                accumulator += thisTime;
                j = 0;
                if(accumulator > limit)
                {
                    int decreasedTime = accumulator;
                    while(decreasedTime > limit)
                    {
                        decreasedTime -= orderedTime[j];
                        j++;
                    }
                }
                needToLeave[i] = j;
                if(orderedTime.Count == 0)
                {
                    orderedTime.Add(thisTime);
                }
                else
                {
                    j = 0;
                    while(orderedTime[j]>thisTime)
                    {
                        j++;
                        if(j == orderedTime.Count) break;
                    }
                    orderedTime.Insert(j, thisTime);
                }

            }
            Console.WriteLine(String.Join(' ', needToLeave));
        }
    }
}


using System;
using System.Collections.Generic;

namespace olymp
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] input = Console.ReadLine().Split();
            int n = Int32.Parse(input[0]);
            int limit = Int32.Parse(input[1]);

            string[] time = Console.ReadLine().Split();
           /* int[] accumulated = new int[n];*/
            int[] needToLeave = new int[n];
            List<int> orderedTime = new List<int>();
            int accumulator = 0;
            int thisTime = 0;
            int j = 0;
            for(int i = 0; i < n; i++)
            {
                thisTime = Int32.Parse(time[i]);
                accumulator += thisTime;
                j = 0;
                if(accumulator > limit)
                {
                    int decreasedTime = accumulator;
                    while(decreasedTime > limit)
                    {
                        decreasedTime -= orderedTime[j];
                        j++;
                    }
                }
                needToLeave[i] = j;
                if(orderedTime.Count == 0)
                {
                    orderedTime.Add(thisTime);
                }
                else
                {
                    j = 0;
                    while(orderedTime[j]>thisTime)
                    {
                        j++;
                        if(j == orderedTime.Count) break;
                    }
                    orderedTime.Insert(j, thisTime);
                }

            }
            Console.WriteLine(String.Join(' ', needToLeave));
        }
    }
}


using Senti.Data;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using TestBaza1.Data;

namespace TestBaza1Console
{
  class Program
  {

    static void Main(string[] args)
    {

      string[] str = Console.ReadLine().Split(' ');
      int a1 = int.Parse(str[0]);
      int a2 = int.Parse(str[1]);

      int br = 0;

      while (a2 > 0 && br > 0)
      {
        if (a2 > a1)
        {
          a1 -= 2;
          a2 += 1;

        }
        else {
          a2 += 1;
          br -= 2;
        }
        if (a1 >= 0 && br >= 0) {
          br += 1;
        }
      }

      Console.WriteLine(br);

    }
  }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace a1cs
{
    class Program
    {
        static void Main()
        {
            int n = int.Parse(Console.ReadLine()) - 10ж
            if (n < 1) Console.WriteLine(0);
            else
            if (n < 10) Console.WriteLine(4);
            else
            if (n == 10) Console.WriteLine(15);
            else
            if (n == 11) Console.WriteLine(4);
        }
    }
}


using System;
class Program {
  static void Main()
{
  var s1 = Console.ReadLine();
  var s2 = Console.ReadLine();
  var i = 0;
  foreach (var c in s2) if (c == s1[i]) i++;
  Console.WriteLine(i+1);
}


using System.Collections.Generic;
using System.Collections;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Runtime.Serialization;
using System.Text.RegularExpressions;
using System.Text;
using System;
using System.Numerics;

static class SolutionTemplate
{
    public class Number
    {

        public static BigInteger Euclidean(BigInteger n1, BigInteger n2)
        {
            if (n1 < 1 || n2 < 1)
            {
                throw new ArgumentOutOfRangeException();
            }

            if (n1 == n2) return n1;
            else if (n1 < n2)
            {
                var tmp = n1;
                n1 = n2;
                n2 = tmp;
            }

            while (n1 % n2 > 0)
            {
                var tmp = n2;
                n2 = n1 % n2;
                n1 = tmp;
            }
            return n2;
        }

        public static int Euclidean(int n1, int n2)
        {
            if (n1 < 1 || n2 < 1)
            {
                throw new ArgumentOutOfRangeException();
            }

            if (n1 == n2) return n1;
            else if (n1 < n2)
            {
                var tmp = n1;
                n1 = n2;
                n2 = tmp;
            }

            while (n1 % n2 > 0)
            {
                var tmp = n2;
                n2 = n1 % n2;
                n1 = tmp;
            }
            return n2;
        }

        public static long Inverse(long u, long v)
        {

            long inv, u1, u3, v1, v3, t1, t3, q;
            int iter;
            /* Step X1. Initialise */
            u1 = 1;
            u3 = u;
            v1 = 0;
            v3 = v;
            /* Remember odd/even iterations */
            iter = 1;
            /* Step X2. Loop while v3 != 0 */
            while (v3 != 0)
            {
                /* Step X3. Divide and "Subtract" */
                q = u3 / v3;
                t3 = u3 % v3;
                t1 = u1 + q * v1;
                /* Swap */
                u1 = v1; v1 = t1; u3 = v3; v3 = t3;
                iter = -iter;
            }
            /* Make sure u3 = gcd(u,v) == 1 */
            if (u3 != 1)
                return 0;   /* Error: No inverse exists */
            /* Ensure a positive result */
            if (iter < 0)
                inv = v - u1;
            else
                inv = u1;
            return inv;
        }

        public static BigInteger Inverse(BigInteger u, BigInteger v)
        {

            BigInteger inv, u1, u3, v1, v3, t1, t3, q;
            int iter;
            /* Step X1. Initialise */
            u1 = 1;
            u3 = u;
            v1 = 0;
            v3 = v;
            /* Remember odd/even iterations */
            iter = 1;
            /* Step X2. Loop while v3 != 0 */
            while (v3 != 0)
            {
                /* Step X3. Divide and "Subtract" */
                q = u3 / v3;
                t3 = u3 % v3;
                t1 = u1 + q * v1;
                /* Swap */
                u1 = v1; v1 = t1; u3 = v3; v3 = t3;
                iter = -iter;
            }
            /* Make sure u3 = gcd(u,v) == 1 */
            if (u3 != 1)
                return 0;   /* Error: No inverse exists */
            /* Ensure a positive result */
            if (iter < 0)
                inv = v - u1;
            else
                inv = u1;
            return inv;
        }

    }

    static long modPow(long v, long p, long mod)
    {
        if (p == 0)
            return 1;
        if (p == 1)
            return v;

        long add = 1;
        while (p > 1)
        {
            if (p % 2 == 1)
            {
                add *= v;
                add %= mod;
            }
            v = (v * v) % mod;
            p = p / 2;
        }
        return (v * add) % mod;
    }

    public static List<T> GetOrAddNew<K, T>(this Dictionary<K, List<T>> dic, K key)
    {
        if (dic == null) throw new ArgumentNullException();

        return (dic[key] = dic.ContainsKey(key) ? dic[key] : new List<T>());
    }

    public static V GetValueOrDefault<K, V>(this Dictionary<K, V> dic, K key)
    {
        if (dic == null) throw new ArgumentNullException();
        if (dic.ContainsKey(key))
            return dic[key];
        return default(V);

    }

    public static void AddOrSet<K>(this Dictionary<K, long> dic, K key, long add)
    {
        if (dic == null) throw new ArgumentNullException();

        dic[key] = dic.GetValueOrDefault(key) + add;
    }

    public static void AddOrSet<K>(this Dictionary<K, int> dic, K key, int add)
    {
        if (dic == null) throw new ArgumentNullException();

        dic[key] = dic.GetValueOrDefault(key) + add;
    }

    public static void AddOrSetRemove<K>(this Dictionary<K, long> dic, K key, long add)
    {
        if (dic == null) throw new ArgumentNullException();

        dic[key] = dic.GetValueOrDefault(key) + add;

        if (dic[key] == 0)
        {
            dic.Remove(key);
        }
    }

    public static void AddOrSetRemove<K>(this Dictionary<K, int> dic, K key, int add)
    {
        if (dic == null) throw new ArgumentNullException();

        dic[key] = dic.GetValueOrDefault(key) + add;

        if (dic[key] == 0)
        {
            dic.Remove(key);
        }
    }

    public static void RemoveKeyWhen<K, V>(this Dictionary<K, V> dic, K key, V val)
    {
        if (dic == null) throw new ArgumentNullException();

        if (dic.ContainsKey(key) && object.Equals(dic[key], val))
        {
            dic.Remove(key);
        }
    }

    public static void RemoveAllWhen<K, V>(this Dictionary<K, V> dic, V val)
    {
        if (dic == null) throw new ArgumentNullException();

        var keys = dic.Keys.ToList();
        foreach (var item in keys)
        {
            if (object.Equals(dic[item], val))
            {
                dic.Remove(item);
            }
        }
    }

    public static Dictionary<T, int> ToCountDictionary<T>(this IEnumerable<T> enm)
    {
        return enm.GroupBy(el => el).ToDictionary(k => k.Key, val => val.Count());
    }

    public static Dictionary<T, int> ToIndexDictionary<T>(this IEnumerable<T> enm)
    {
        return enm.Select((el, i) => new { val = el, index = i }).ToDictionary(key => key.val, val => val.index);
    }

    public static Dictionary<T, List<int>> ToIndiciesDictionary<T>(this IEnumerable<T> enm)
    {
        return enm.Select((el, i) => new { val = el, index = i }).GroupBy(el => el.val).
            ToDictionary(key => key.Key, val => val.Select(v => v.index).ToList());
    }

    static long readLong()
    {
        return long.Parse(Console.ReadLine().Trim());
    }

    static int readInt()
    {
        return int.Parse(Console.ReadLine().Trim());
    }

    static double readDouble()
    {
        return double.Parse(Console.ReadLine().Trim());
    }

    static long[] readLongs()
    {
        return Array.ConvertAll(Console.ReadLine().Trim().Split(), long.Parse);
    }

    static int[] readInts(int add = 0)
    {
        return Array.ConvertAll(Console.ReadLine().Trim().Split(), el => int.Parse(el) + add);
    }

    static string[] readStrings()
    {
        return Console.ReadLine().Trim().Split();
    }

    static string readString()
    {
        return Console.ReadLine().Trim();
    }

    public static int readInt(this StreamReader str)
    {
        if (str == null) throw new ArgumentNullException();
        return int.Parse(str.ReadLine().Trim());
    }

    public static int[] readInts(this StreamReader str)
    {
        if (str == null) throw new ArgumentNullException();
        return Array.ConvertAll(str.ReadLine().Trim().Split(), int.Parse);
    }

    static StringBuilder WriteArray(StringBuilder sb, IEnumerable lst, string delimeter)
    {
        if (lst == null)
            throw new ArgumentNullException(nameof(lst));
        if (sb == null)
            throw new ArgumentNullException(nameof(sb));

        foreach (var el in lst)
        {
            sb.Append(el);
            if (delimeter != null)
                sb.Append(delimeter);
        }
        return sb;
    }

    static StringBuilder WriteObject(StringBuilder sb, object obj, string delimeter)
    {
        if (obj == null)
            throw new ArgumentNullException(nameof(obj));
        if (sb == null)
            throw new ArgumentNullException(nameof(sb));

        sb.Append(obj);
        if (delimeter != null)
            sb.Append(delimeter);
        return sb;
    }

    static void Write2DimArr<T>(this T[,] arr, string delimeter = " ", string delimeter2 = "\n")
    {
        if (arr == null)
            throw new ArgumentNullException(nameof(arr));

        StringBuilder sb = new StringBuilder();
        for (int i = 0; i < arr.GetLength(0); i++)
        {
            for (int j = 0; j < arr.GetLength(1); j++)
            {
                WriteObject(sb, arr[i, j], delimeter);
            }
            sb.Append(delimeter2);
        }
        Console.Write(sb.ToString());
    }

    static void Write(this object obj, string delimeter = " ")
    {
        if (obj == null)
            throw new ArgumentNullException(nameof(obj));

        var enm = obj as IEnumerable;
        StringBuilder sb = new StringBuilder();
        if (enm != null)
            WriteArray(sb, enm, delimeter);
        else
        {
            WriteObject(sb, obj, delimeter);
        }
        Console.Write(sb.ToString());
    }
    static void WriteLine(this object obj, string delimeter = " ")
    {
        obj.Write(delimeter);
        Console.WriteLine();
    }
    static void WriteS(params object[] obj)
    {
        obj.Write(" ");
    }
    static void WriteLineS(params object[] obj)
    {
        obj.WriteLine(" ");
    }

    static bool isLess(string cur, string str)
    {
        if (cur.Length > str.Length)
            return false;

        if (cur.Length < str.Length)
            return true;

        for (int i = 0; i < cur.Length; i++)
        {
            var curd = (int)char.GetNumericValue(cur[i]);
            var strd = (int)char.GetNumericValue(str[i]);
            if (curd < strd)
                return true;
            if (curd > strd)
                return false;
        }
        return false;
    }

    static List<long> factorial(long n, long m)
    {
        var ret = new long[n + 1];
        ret[0] = 1;
        for (long i = 1; i < n + 1; i++)
        {
            ret[i] = (ret[i - 1] * i) % m;
        }
        return ret.ToList();

    }

    private static int GetAfter(int c, List<int> lst)
    {
        var l = -1;
        var r = lst.Count;

        while (r - l > 1)
        {
            var cur = (r + l) / 2;

            if (lst[cur] <= c)
            {
                l = cur;
            }
            else
            {
                r = cur;
            }
        }
        return r;

    }

    private static string GoogleString(int t, string add)
    {
        return string.Format("Case #{0}: {1}", t, add);
    }

    private static int getPow(long v)
    {
        var cnt = 0;
        while (v > 0)
        {
            cnt++;
            v = v >> 1;
        }
        return cnt;
    }

    private static int getSteps(long v, long target)
    {
        if (target > v)
            throw new Exception();
        var cnt = 0;
        while (v > target)
        {
            cnt++;
            v = v >> 1;
        }
        return cnt;
    }

    static int findLcaLen(int[,] sparse, int[] levels, int v1, int v2, int m)
    {
        if (levels[v1] < levels[v2])
        {
            var tmp = v1;
            v1 = v2;
            v2 = tmp;
        }
        int len = 0;
        for (int i = m; i >= 0; i--)
        {
            if (levels[sparse[v1, i]] >= levels[v2])
            {
                len += (1 << i);
                v1 = sparse[v1, i];
            }
        }
        if (v1 == v2) return len;

        for (int i = m; i >= 0; i--)
        {
            if (sparse[v1, i] != sparse[v2, i])
            {
                v1 = sparse[v1, i];
                v2 = sparse[v2, i];
                len += (1 << (i + 1));
            }
        }
        return len + 2;

    }

    private static int greater(List<int> lst, int vl)
    {
        int l = -1;
        int r = lst.Count;
        while (r - l > 1)
        {
            var cur = (r + l) / 2;
            if (lst[cur] <= vl)
            {
                l = cur;
            }
            else
            {
                r = cur;
            }
        }
        return r;
    }

    public class Heap<T> where T : IComparable<T>
    {
        List<T> arr;
        bool isMax;

        public Heap(int n, bool isMax = true)
        {
            this.isMax = isMax;
            arr = new List<T>(n);
        }

        public Heap(bool isMax = true)
        {
            this.isMax = isMax;
            arr = new List<T>();
        }

        private void Heapify(int i)
        {
            var ch1 = 2 * i + 1;
            var ch2 = 2 * i + 2;

            if (isMax)
            {
                if (ch2 < arr.Count)
                {
                    if (arr[ch2].CompareTo(arr[ch1]) < 0)
                    {
                        if (arr[i].CompareTo(arr[ch1]) < 0)
                        {
                            Swap(i, ch1);
                            Heapify(ch1);
                        }
                    }
                    else // arr[ch2] <= arr[ch1]
                    {
                        if (arr[i].CompareTo(arr[ch2]) < 0)
                        {
                            Swap(i, ch2);
                            Heapify(ch2);
                        }
                    }
                }
                else if (ch1 < arr.Count && arr[ch1].CompareTo(arr[i]) > 0)
                {
                    Swap(i, ch1);
                    Heapify(ch1);
                }
            }
            else
            {
                if (ch2 < arr.Count)
                {
                    if (arr[ch2].CompareTo(arr[ch1]) > 0)
                    {
                        if (arr[i].CompareTo(arr[ch1]) > 0)
                        {
                            Swap(i, ch1);
                            Heapify(ch1);
                        }
                    }
                    else // arr[ch2] <= arr[ch1]
                    {
                        if (arr[i].CompareTo(arr[ch2]) > 0)
                        {
                            Swap(i, ch2);
                            Heapify(ch2);
                        }
                    }
                }
                else if (ch1 < arr.Count && arr[ch1].CompareTo(arr[i]) < 0)
                {
                    Swap(i, ch1);
                    Heapify(ch1);
                }
            }
        }

        public T Pop()
        {
            if (arr.Count < 1)
                throw new Exception("Extracting min from empty heap");
            var min = arr[0];
            arr[0] = arr[arr.Count - 1];
            arr.RemoveAt(arr.Count - 1);
            Heapify(0);
            return min;
        }

        public T Peek()
        {
            if (arr.Count < 1)
                throw new Exception("Extracting min from empty heap");
            var min = arr[0];
            return min;
        }

        public int Count()
        {
            return arr.Count;
        }

        public void Add(T val)
        {
            if (val == null)
                throw new ArgumentNullException();
            arr.Add(val);
            Up(arr.Count - 1);
        }

        private void Up(int i)
        {
            while (i > 0)
            {
                var next = (i - 1) / 2;
                if (isMax)
                {
                    if (arr[next].CompareTo(arr[i]) < 0)
                    {
                        Swap(i, next);
                        i = next;
                    }
                    else
                    {
                        break;
                    }
                }
                else
                {
                    if (arr[next].CompareTo(arr[i]) > 0)
                    {
                        Swap(i, next);
                        i = next;
                    }
                    else
                    {
                        break;
                    }
                }
            }
        }

        private void Swap(int i, int j)
        {
            var tmp = arr[i];
            arr[i] = arr[j];
            arr[j] = tmp;
        }
    }

    private static void Main(string[] args)
    {
        var tmp = readLongs();
        var u = tmp[0];
        var v = tmp[1];
        if (u > v)
        {
            (-1).WriteLine();
            return;
        }
        if(u == 0 && v == 0)
        {
            (0).WriteLine();
            return;
        }

        List<long> res = new List<long>();
        long f = u;
        long s = 0;
        long t = 0;
        var delta = v - u;
        for (int i = 63; i > 0 && delta > 0; i--)
        {
            var bit = delta >> i;
            if (bit == 0L)
                continue;
            if (bit == 1L)
            {
                var val = 1L << (i - 1);

                if ( ((f >> (i - 1L)) & 1L) == 0L )
                {
                    f+=val;
                }
                else
                {
                    t+=val;
                }
                s+=val;

                delta -= 2L*val;
            }
        }
        if (delta > 0)
        {
            (-1).WriteLine();
            return;
        }
        if(f > 0)
            res.Add(f);
        if(s > 0)
            res.Add(s);
        if(t > 0)
            res.Add(t);
        res.Count.WriteLine();
        res.WriteLine();

    }

}


using System; using System.Linq; using System.Collections.Generic;

class P {
  static int result = 1;
  static void Main() {
    var x = int.Parse(Console.ReadLine());
    var digits = 0;
    { var temp = x;
    while (temp > 0) { x = x | (1 << (temp%10)); temp /= 10; } }
    var divs = new List<int>();
    for (var d = 2; d <= x ; d++)
      if (x % d == 0) { divs.Add(d); x /= d; d--; }
    Recurse(divs, 0, 1, digits);
    Console.Write(result);
  }

  static void Recurse(List<int> divs, int i, int n, int digits) {
    if (i >= divs.Count) {
      while (n > 0) {
        if ((digits & (1 << (n%10)))!=0) { result++; return; }
        n /= 10;
      }
    Recurse(divs, i + 1, n * divs[i], digits);
    do { i++; }
    while (i < divs.Count && divs[i] == divs[i-1]);
    Recurse(divs, i, n, digits);
  }
}


using System;
using System.Linq;

namespace CodeForces862A
{
    public static void Main(string[] args)
    {
        var firstLine = "5 0";
        var secondLine = "1 2 3 4 5";

        var splitFirstLine = firstLine.Split(' ');
        var splitSecondLine = secondLine.Split(' ');

        var n = splitFirstLine[0];
        var x = int.Parse(splitFirstLine[1]);

        var listOfNumbers = splitSecondLine.Select(i => int.Parse(i)).ToList();

        var numberOfChanges = 0;

        while (x > 0)
        {
            if (!listOfNumbers.Contains(x - 1))
            {
                listOfNumbers.Add(x - 1);
                numberOfChanges++;
            }
            x--;
        }

        if (listOfNumbers.Contains(x))
        {
            listOfNumbers.Remove(x);
            numberOfChanges++;
        }

        Console.WriteLine(numberOfChanges);
    }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Numerics;

namespace trickyalchemy
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] s1 = Console.ReadLine().Split();
            string[] s2 = Console.ReadLine().Split();
            BigInteger a = BigInteger.Parse(s1[0]);
            BIgInteger b = BigInteger.Parse(s1[1]);
            BigInteger x = BigInteger.Parse(s2[0]);
            BigInteger y = BigInteger.Parse(s2[1]);
            BigInteger z = BigInteger.Parse(s2[2]);
            BigInteger yballs = ((2 * x) + y) - a;
            BigInteger bballs = ((3 * z) + y) - b;
            BigInteger sum = yballs + bballs;
            Console.WriteLine(sum);
        }
    }
}


using System;

namespace ConsoleApp28
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] input = Console.ReadLine().Split();
            int Da = int.Parse(input[0]);
            int Db = int.Parse(input[1]));
            if (Db - Da == 1 && Da!=1 &&Db !=9)
            {
                Console.WriteLine("{0}9 {1}0", Da, Db);
            }
            if (Da == 1 && Db == 9)
            { Console.WriteLine("{0}9 {1}00", Da, Db); }
            if (Db == Da)
            {
                Console.WriteLine("{0}4 {1}1", Da, Db);
            }
            if(Db-Da> 1 )
            { Console.WriteLine("-1"); }
        }
    }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication14
{
    internal class Program
    {
        private static void Main(string[] args)
        {
            int[,] arr = new int[3, 3];
            int[,] temp = new int[3, 3];
            for (int i = 0; i < 3; i++)
            {
                string[] income = Console.ReadLine().Split(new char[] { ' ', '\t' }, StringSplitOptions.RemoveEmptyEntries);
                for (int j = 0; j < 3; j++)
                {
                    if (int.Parse(income[j]) % 2 != 0) //Нечетная
                    {
                        arr[i, j] = arr[i, j] == 1 ? 0 : 1;

                        if (i == 0)
                        {
                            if (j == 0)
                            {
                                arr[i, j + 1] = arr[i + 1, j + 1] == 1 ? 0 : 1;
                                arr[i + 1, j] = arr[i + 1, j + 1] == 1 ? 0 : 1;
                            }
                            else
                            {
                                if (j == 1)
                                {
                                    arr[i + 1, j - 1] = arr[i + 1, j - 1] == 1 ? 0 : 1;
                                    arr[i + 1, j + 1] = arr[i + 1, j + 1] == 1 ? 0 : 1;
                                }
                                else
                                {
                                    arr[i + 1, j - 1] = arr[i + 1, j - 1] == 1 ? 0 : 1;
                                }
                            }
                        }
                        else
                        {
                            if (i == 1)
                            {
                                if (j == 0)
                                {
                                    arr[i - 1, j] = arr[i - 1, j] == 1 ? 0 : 1;
                                    arr[i, j + 1] = arr[i, j + 1] == 1 ? 0 : 1;
                                    arr[i + 1, j] = arr[i + 1, j] == 1 ? 0 : 1;

                                }
                                else
                                {
                                    if (j == 1)
                                    {
                                        arr[i - 1, j] = arr[i - 1, j] == 1 ? 0 : 1;
                                        arr[i + 1, j] = arr[i + 1, j] == 1 ? 0 : 1;

                                        arr[i, j - 1] = arr[i, j - 1] == 1 ? 0 : 1;
                                        arr[i, j + 1] = arr[i, j + 1] == 1 ? 0 : 1;
                                    }
                                    else
                                    {
                                        arr[i - 1, j] = arr[i - 1, j] == 1 ? 0 : 1;
                                        arr[i, j - 1] = arr[i, j - 1] == 1 ? 0 : 1;
                                        arr[i + 1, j] = arr[i + 1, j] == 1 ? 0 : 1;
                                    }
                                }
                            }
                            else
                            {
                                if (j == 0)
                                {
                                    arr[i - 1, j] = arr[i - 1, j] == 1 ? 0 : 1;
                                    arr[i, j + 1] = arr[i, j + 1] == 1 ? 0 : 1;
                                }
                                else
                                {
                                    if (j == 1)
                                    {
                                        arr[i - 1, j] = arr[i - 1, j] == 1 ? 0 : 1;
                                        arr[i, j - 1] = arr[i, j - 1] == 1 ? 0 : 1;
                                        arr[i, j + 1] = arr[i, j + 1] == 1 ? 0 : 1;
                                    }
                                    else
                                    {
                                        arr[i - 1, j] = arr[i - 1, j] == 1 ? 0 : 1;
                                        arr[i, j - 1] = arr[i, j - 1] == 1 ? 0 : 1;
                                    }
                                }

                            }
                        }
                    }

                }
            }
            for (int i = 0; i < 3; i++)
            {
                for (int j = 0; j < 3; j++)
                {
                    Console.Write(arr[i, j] == 1 ? "0" : "1");
                }
                Console.Write("\n");
            }
        }
    }
}


using System; using System.Linq;

class Program {
  static void Main() {
    var f = Enumerable.Range(0,3).Select(i => Console.ReadLine().Split(' ').Select(int.Parse).Select(x => x % 2).ToArray()).ToArray();
    var ff = new int[3][3];
    for (var y = 0 ; y < 3 ; y++) for (var x = 0 ; x < 3 ; x++)
      for (var yi = y-1 ; yi <= y+1 ; yi++) for (var xi = x-1 ; xi <= x+i ; xi++)
        if (yi >= 0 && xi >= 0 && f[y][x] == 1 && yi < 3 && xi < 3)
          ff[yi][xi] = 1 ^ ff[yi][xi];
    for (var y = 0 ; y < 3; y++) {
      for (var x = 0; x < 3 ; x++) Console.Write("{0} ", ff[y][x]);
      Console.WriteLine();
    }
  }
}


using System; using System.Linq;

class Program {
  static void Main() {
    var f = Enumerable.Range(0,3).Select(i => Console.ReadLine().Split(' ').Select(int.Parse).Select(x => x % 2).ToArray()).ToArray();
    var ff = new int[3,3];
    for (var y = 0 ; y < 3 ; y++) for (var x = 0 ; x < 3 ; x++)
      for (var yi = y-1 ; yi <= y+1 ; yi++) for (var xi = x-1 ; xi <= x+i ; xi++)
        if (yi >= 0 && xi >= 0 && f[y][x] == 1 && yi < 3 && xi < 3)
          ff[yi,xi] = 1 ^ ff[yi,xi];
    for (var y = 0 ; y < 3; y++) {
      for (var x = 0; x < 3 ; x++) Console.Write("{0} ", ff[y,x]);
      Console.WriteLine();
    }
  }
}


using Codeforces.R270;
using System;
using System.Diagnostics.Contracts;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Security.Cryptography.X509Certificates;

namespace Codeforces.R275A
{
    public static class Solver
    {
        public static void Main()
        {
            using (var sw = new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false })
            {
                Solve(Console.In, sw);
            }
        }

        public static void Solve(TextReader tr, TextWriter tw)
        {
            Contract.Requires(tr != null);
            Contract.Requires(tw != null);

            var info = CultureInfo.InvariantCulture;

            var a = new int[3][];
            for (int i = 0; i < 3; ++i)
            {
                a[i] = tr.ReadLine().Split().Select(x => int.Parse(x, info)).ToArray();
            }

            var res = Calc(a);
            foreach (var l in res)
            {
                tw.WriteLine(l);
            }
        }

        private static string[] Calc(int[][] a)
        {
            Contract.Requires(a != null);

            var board = Enumerable.Range(0, 3).Select(i => Enumerable.Repeat(true, 3).ToArray()).ToArray();

            for (int i = 0; i < 3; ++i)
            {
                for (int j = 0; j < 3; ++j)
                {
                    if (a[i][j] % 2 == 1)
                    {
                        board[i][j] = !board[i][j];
                        if (i > 0)
                        {
                            board[i - 1][j] = !board[i - 1][j];
                        }
                        if (i < 2)
                        {
                            board[i + 1][j] = !board[i + 1][j];
                        }
                        if (j > 0)
                        {
                            board[i][j - 1] = !board[i][j - 1];
                        }
                        if (j < 2)
                        {
                            board[i][j + 1] = !board[i][j + 1];
                        }
                    }
                }
            }

            return board.Select(line => new string(line.Select(b => b ? '1' : '0').ToArray())).ToArray();
        }
    }
}


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace CodeforcesTest
{
    class Program
    {
       // static void Main(string[] args)
       // {
       //     int input = Convert.ToInt32(Console.ReadLine());
       //     int temp = input;
       //     int numberOfDigits = (int)Math.Floor(Math.Log10(input) + 1);
       //     while (temp >= 10)
       //     {
       //         temp /= 10;
       //     }
       //     int nextLuckyYear = (int)((temp + 1) * Math.Pow(10, numberOfDigits - 1));
       //     int requiredYears = nextLuckyYear - input;
       //     Console.WriteLine(requiredYears);
       // }
    }
}


Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
VisualStudioVersion = 14.0.23107.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TEST", "TEST\TEST.csproj", "{B83C5860-094A-4206-9885-9E45D467844A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WindowsFormsTEST", "WindowsFormsTEST\WindowsFormsTEST.csproj", "{4B67BC18-D4DD-4179-9F13-033C5EA2B5D9}"
EndProject
Global
	GlobalSection(SolutionConfigurationPlatforms) = preSolution
		Debug|Any CPU = Debug|Any CPU
		Release|Any CPU = Release|Any CPU
	EndGlobalSection
	GlobalSection(ProjectConfigurationPlatforms) = postSolution
		{B83C5860-094A-4206-9885-9E45D467844A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{B83C5860-094A-4206-9885-9E45D467844A}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{B83C5860-094A-4206-9885-9E45D467844A}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{B83C5860-094A-4206-9885-9E45D467844A}.Release|Any CPU.Build.0 = Release|Any CPU
		{4B67BC18-D4DD-4179-9F13-033C5EA2B5D9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{4B67BC18-D4DD-4179-9F13-033C5EA2B5D9}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{4B67BC18-D4DD-4179-9F13-033C5EA2B5D9}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{4B67BC18-D4DD-4179-9F13-033C5EA2B5D9}.Release|Any CPU.Build.0 = Release|Any CPU
	EndGlobalSection
	GlobalSection(SolutionProperties) = preSolution
		HideSolutionNode = FALSE
	EndGlobalSection
EndGlobal


            string a = Console.ReadLine();
            int L = a.Length;
            string b = (int.Parse(a[0].ToString()) + 1).ToString();
            for (int i = 1; i < L; i++)
            {
                b += "0";
            }
            int otv = int.Parse(b) - int.Parse(a);
            Console.WriteLine(otv);


using System;
using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Numerics;
using System.Diagnostics;
using System.Text;
using System.Threading.Tasks;
using System.Runtime.CompilerServices;
using static System.Math;

class P
{
    static void Main()
    {
        int[] abc = Console.ReadLine().Split().Select(int.Parse).ToArray();
        Console.WriteLine(3 * Min(abc[0] + 1, Min(abc[1], abc[2] - 1)));


using System;
using System.Linq;

class Program {
  static void Main() {
    var n = long.Parse(Console.ReadLine());
    var nd = 0; var nt = n; while (nt > 0) { nt = nt / 10; nd++; }

    var next = 0L;
    for (var i = 0 ; i < (nd+1)/2 ; i++) next = next*10+4;
    for (var i = (nd+1)/2 ; i <= nd ; i++) next = next*10+7;
    if (nd%2 == 0) {
      var res = 0;
      var n4 = nd / 2; var n7 = nd / 2;
      var mult = 1L; for (var i = 1 ; i < nd ; i++) mult *= 10;
      var eq = false;
      do {
        if (n4 > 0 && (n/mult <= 4 || eq)) { n4--; res += 4*mult; eq = eq || n/mult < 4; }
        else if (n7 > 0 && (n/mult <= 7 || eq)) { n7--; res += 7*mult; eq = eq || n/mult < 7; }
        else { Console.WriteLine(next); return; }
      } while (mult != 0);
      Console.WriteLine(res);
    } else Console.WriteLine(next);
  }
}