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

#region testlib
public delegate bool ParserDelegate<T>(string word, out T item);

public class Input : IDisposable
{
private static EventArgs DefaultEventArgs = new EventArgs();

public TextReader TextReader { get; private set; }

public event EventHandler OnEndOfStream;
public event EventHandler OnParseError;
public event EventHandler OnReadError;

public bool CanRead { get; private set; }
public bool ThrowExceptions { get; set; }

string line = string.Empty;
int pos = 0;

static EventHandler emptyHandler;

public Input(string path)
: this(File.OpenRead(path))
{
}
public Input(Stream s)
: this(new StreamReader(s))
{

}
public Input(TextReader tr)
{
TextReader = tr;

if (emptyHandler == null)
emptyHandler = (a, b) => { };

OnEndOfStream = emptyHandler;
OnParseError = emptyHandler;
OnReadError = emptyHandler;

CanRead = true;
}

public static implicit operator Input(Stream s)
{
return new Input(s);
}
public static implicit operator Input(TextReader tr)
{
return new Input(tr);
}

private bool ReadStream()
{
if (!CanRead) return false;
if (pos < line.Length) return true;

Clear();

string s = TextReader.ReadLine();
if (s == null)
{
CanRead = false;
return false;
}

line = s;
return true;
}

public void SkipChar()
{
if (pos < line.Length) pos++;
else
{
ReadStream();
}
}
public void SkipChars(int length)
{
while (length > 0)
{
int dt = line.Length - pos;
if (dt <= 0)
{
length--;
if (!ReadStream()) return;
}
dt = Math.Min(length, dt);
pos += dt;
length -= dt;
}
}

public void SkipWhiteSpace()
{
while (true)
{
for (; pos < line.Length; pos++)
{
if (!char.IsWhiteSpace(line[pos])) return;
}
if (!ReadStream())
{
OnEndOfStream(this, DefaultEventArgs);
return;
}
}
}
public bool CanReadData()
{
SkipWhiteSpace();
return CanRead;
}

public T[] ReadArray<T>()
{
int length = ReadInt32();
return ReadArray<T>(length);
}
public T[] ReadArray<T>(int length)
{
ParserDelegate<T> parser = Parser.GetPrimitiveParser<T>();
return ReadArray<T>(length, parser);
}
public T[] ReadArray<T>(ParserDelegate<T> parser)
{
int length = ReadInt32();
return ReadArray<T>(length, parser);
}
public T[] ReadArray<T>(int length, ParserDelegate<T> parser)
{
T[] res = new T[length];
for (int i = 0; i < length; i++)
{
res[i] = ReadData<T>(parser);
}
return res;
}

public Decimal ReadDecimal()
{
return ReadData<Decimal>(Parser.DecimalParser);
}
public Double ReadDouble()
{
return ReadData<Double>(Parser.DoubleParser);
}
public Single ReadSingle()
{
return ReadData<Single>(Parser.SingleParser);
}
public UInt64 ReadUInt64()
{
return ReadData<UInt64>(UInt64.TryParse);
}
public UInt32 ReadUInt32()
{
return ReadData<UInt32>(UInt32.TryParse);
}
public UInt16 ReadUInt16()
{
return ReadData<UInt16>(UInt16.TryParse);
}
public Int64 ReadInt64()
{
return ReadData<Int64>(Int64.TryParse);
}
public Int32 ReadInt32()
{
return ReadData<Int32>(Int32.TryParse);
}
public Int16 ReadInt16()
{
return ReadData<Int16>(Int16.TryParse);
}
public Boolean ReadYesNo()
{
return ReadData<Boolean>(Parser.YesNoParser);
}
public Boolean ReadBoolean()
{
return ReadData<Boolean>(Boolean.TryParse);
}
public Byte ReadByte()
{
return ReadData<Byte>(Byte.TryParse);
}

private bool ReadCheck()
{
if (!CanRead)
{
OnReadError(this, DefaultEventArgs);
if (ThrowExceptions)
{
throw new Exception("!CanRead");
}
return false;
}
return true;
}
public T ReadData<T>()
{
return ReadData<T>(true);
}
public T ReadData<T>(bool skipWhiteSpace)
{
ParserDelegate<T> parser = Parser.GetPrimitiveParser<T>();
return ReadData<T>(parser, skipWhiteSpace);
}
public T ReadData<T>(ParserDelegate<T> parser)
{
return ReadData<T>(parser, true);
}
public T ReadData<T>(ParserDelegate<T> parser, bool skipWhiteSpace)
{
if (skipWhiteSpace)
SkipWhiteSpace();

if (!ReadCheck()) return default(T);

string s = ReadWord(false);

T res;
if (!parser.Invoke(s, out res))
{
OnParseError(this, DefaultEventArgs);
if (ThrowExceptions)
{
throw new Exception("!validate, word = " + Output.ToString(s, 256));
}
}
return res;
}

public string ReadWord()
{
return ReadWord(true);
}
public string ReadWord(bool skipWhiteSpace)
{
if (skipWhiteSpace)
SkipWhiteSpace();

if (!ReadCheck()) return string.Empty;

int from = pos;
int to = pos;
for (int i = pos; i < line.Length; i++)
{
if (char.IsWhiteSpace(line[i])) break;
to = i + 1;
}
pos = to;

return line.Substring(from, to - from);
}

public string ReadLine()
{
if (!ReadCheck()) return string.Empty;

ReadStream();
string res = line.Substring(pos);
pos = line.Length;

return res;
}

public void Close()
{
TextReader.Close();
}
public void Clear()
{
pos = 0;
line = string.Empty;
}

private bool disposed = false;
public void Dispose()
{
Dispose(true);
GC.SuppressFinalize(this);
}

protected virtual void Dispose(bool disposing)
{
if (!this.disposed)
{
if (disposing)
{
line = string.Empty;
TextReader.Dispose();
}
disposed = true;
}
}
~Input()
{
Dispose(false);
}
}
public class Output : IDisposable
{
static char[] space = new char[] { ' ' };

public TextWriter TextWriter { get; private set; }
public bool AutoFlush { get; set; }

public static string ToString(object obj, int maxLength)
{
return ToString(FormatReal(obj), maxLength);
}
public static string ToString(string s, int maxLength)
{
if (s.Length <= maxLength) return s;
else return s.Substring(0, maxLength) + "...";
}
public static object FormatReal(object v, string format)
{
if (v is decimal) return ((decimal)v).ToString(format).Replace(',', '.');
if (v is double) return ((double)v).ToString(format).Replace(',', '.');
if (v is float) return ((float)v).ToString(format).Replace(',', '.');

return v;
}
public static object FormatReal(object v)
{
if (v is decimal || v is double || v is float)
{
return v.ToString().Replace(',', '.');
}
return v;
}

public Output()
: this(new MemoryStream())
{
}
public Output(string path)
: this(File.Create(path))
{

}
public Output(Stream s)
: this(new StreamWriter(s))
{
}
public Output(TextWriter tw)
{
TextWriter = tw;
}

public static implicit operator Output(Stream s)
{
return new Output(s);
}

public static implicit operator Output(TextWriter tw)
{
return new Output(tw);
}

public static Output operator +(Output output, object obj)
{
output.Write(obj);
return output;
}
public Output WriteArray<T>(params T[] array)
{
return WriteArray<T>(array, false);
}
public Output WriteArray<T>(T[] array, bool appendLength)
{
return WriteArray<T>(array, 0, array.Length, appendLength);
}
public Output WriteArray<T>(T[] array, int index, int count)
{
return WriteArray<T>(array, index, count, false);
}
public Output WriteArray<T>(T[] array, int index, int count, bool appendLength)
{
if (index + count > array.Length)
{
string message = string.Format(
"Index out of range: {0} + {1} >= {2}",
index,
count,
array.Length);
throw new Exception(message);
}
if (appendLength)
{
WriteLine(count);
}
for (int i = 0; i < count; i++)
{
Write(array[i]);
Write(space, 0, space.Length);
}
WriteLine();

return this;
}
public Output WriteLine(object obj)
{
obj = FormatReal(obj);
return WriteLine(obj.ToString());
}
public Output WriteLine(string format, params object[] args)
{
return WriteLine(string.Format(format, args));
}
public Output WriteLine(string s)
{
return WriteLine(s.ToCharArray());
}
public Output WriteLine(char[] buffer)
{
return WriteLine(buffer, 0, buffer.Length);
}
public Output WriteLine(char[] buffer, int index, int count)
{
TextWriter.WriteLine(buffer, index, count);
if (AutoFlush) TextWriter.Flush();
return this;
}
public Output WriteLine()
{
TextWriter.WriteLine();
if (AutoFlush) TextWriter.Flush();
return this;
}
public Output Write(object obj)
{
obj = FormatReal(obj);
return Write(obj.ToString());
}
public Output Write(string format, params object[] args)
{
return Write(string.Format(format, args));
}
public Output Write(string s)
{
return Write(s.ToCharArray());
}
public Output Write(char[] buffer)
{
return Write(buffer, 0, buffer.Length);
}
public Output Write(char[] buffer, int index, int count)
{
TextWriter.Write(buffer, index, count);
if (AutoFlush) TextWriter.Flush();
return this;
}

public void Close()
{
TextWriter.Close();
}
public void Flush()
{
TextWriter.Flush();
}

private bool disposed = false;
public void Dispose()
{
Dispose(true);
GC.SuppressFinalize(this);
}

protected virtual void Dispose(bool disposing)
{
if (!this.disposed)
{
if (disposing)
{
TextWriter.Dispose();
}
disposed = true;
}
}
~Output()
{
Dispose(false);
}
}
public static class Parser
{
public static ParserDelegate<T> GetPrimitiveParser<T>()
{
if (!typeof(T).IsPrimitive) throw new Exception("Unknown type");
else if (default(T) is Byte) return new ParserDelegate<Byte>(Byte.TryParse) as ParserDelegate<T>;
else if (default(T) is Boolean) return new ParserDelegate<Boolean>(Boolean.TryParse) as ParserDelegate<T>;
else if (default(T) is Int16) return new ParserDelegate<Int16>(Int16.TryParse) as ParserDelegate<T>;
else if (default(T) is Int32) return new ParserDelegate<Int32>(Int32.TryParse) as ParserDelegate<T>;
else if (default(T) is Int64) return new ParserDelegate<Int64>(Int64.TryParse) as ParserDelegate<T>;
else if (default(T) is UInt16) return new ParserDelegate<UInt16>(UInt16.TryParse) as ParserDelegate<T>;
else if (default(T) is UInt32) return new ParserDelegate<UInt32>(UInt32.TryParse) as ParserDelegate<T>;
else if (default(T) is UInt64) return new ParserDelegate<UInt64>(UInt64.TryParse) as ParserDelegate<T>;
else if (default(T) is Single) return new ParserDelegate<Single>(Parser.SingleParser) as ParserDelegate<T>;
else if (default(T) is Double) return new ParserDelegate<Double>(Parser.DoubleParser) as ParserDelegate<T>;
else if (default(T) is Decimal) return new ParserDelegate<Decimal>(Parser.DecimalParser) as ParserDelegate<T>;
else if (default(T) is String) return new ParserDelegate<String>(Parser.StringParser) as ParserDelegate<T>;
else throw new Exception("Unknown type");
}
public static bool YesNoParser(string s, out Boolean result)
{
s = s.ToLower();
if (s == "yes") result = true;
else if (s == "no") result = false;
else
{
result = false;
return false;
}
return true;
}
public static bool StringParser(string s, out string result)
{
result = s;
return string.IsNullOrEmpty(s);
}
public static bool DecimalParser(string s, out Decimal result)
{
return Decimal.TryParse(s.Replace('.', ','), out result);
}
public static bool DoubleParser(string s, out Double result)
{
return Double.TryParse(s.Replace('.', ','), out result);
}
public static bool SingleParser(string s, out Single result)
{
return Single.TryParse(s.Replace('.', ','), out result);
}
}
#endregion

class V : IComparable<V>
{
    public int Index;
    public int StartT;
    public int EndT;
    public int Count;

    public int CompareTo(V a)
    {
        var r = EndT.CompareTo(a.EndT);
        if (r == 0) r = Count.CompareTo(a.Count);
        if (r == 0) r = Index.CompareTo(a.Index);
        return r;
    }
}
static class Program
{
    #region Streams
    static string endl = Environment.NewLine;
    static Input cin = new Input(Console.In);
    static Output cout = new Output(Console.Out);
    static Output cerr = new Output(Console.Error);

    static void InitIO()
    {
#if !DEBUG
        cin = new Input("input.txt");
        cout = new Output("output.txt");
#endif
    }
    #endregion
    #region Time
    static Stopwatch sw = new Stopwatch();
    static void Start()
    {
        sw.Reset();
        sw.Start();
    }
    static void Restart(string text = "")
    {
        Stop(text);
        Start();
    }
    static void Time(string text = "")
    {
        if (string.IsNullOrEmpty(text))
        {
            cerr.WriteLine(sw.Elapsed);
        }
        else
        {
            cerr.WriteLine(text + ": " + sw.Elapsed);
        }
    }
    static void Stop(string text = "")
    {
        sw.Stop();
        Time(text);
    }
    //*/
    #endregion
    #region Prewriten
    static void Swap<T>(ref T a, ref T b)
    {
        T c = a;
        a = b;
        b = c;
    }
    static long Gcd(long a, long b)
    {
        while (a > 0)
        {
            b %= a;
            Swap(ref a, ref b);
        }
        return b;
    }
    static int[] ZFunction(string s)
    {
        var z = new int[s.Length];
        for (int i = 1, l = 0, r = 0; i < s.Length; ++i)
        {
            if (i <= r)
            {
                z[i] = Math.Min(r - i + 1, z[i - l]);
            }
            while (i + z[i] < s.Length && s[z[i]] == s[i + z[i]])
            {
                z[i]++;
            }
            if (i + z[i] - 1 > r)
            {
                l = i;
                r = i + z[i] - 1;
            }
        }
        return z;
    }
    static long Pow(long a, long p)
    {
        var b = 1L;
        while (p > 0)
        {
            if ((p & 1) == 0)
            {
                a *= a;
                p >>= 1;
            }
            else
            {
                b *= a;
                p--;
            }
        }
        return b;
    }
    #endregion
    const string nyan = "^_^";
    const string name = "canalization";
    const long mod = 1000000007;

    static int Find(string[] a, char x)
    {
        var blocked = new bool[8];
        for (var i = 0; i < 8; i++)
        {
            for (var j = 0; j < 8; j++)
            {
                if (a[i][j] == x && !blocked[j]) return i;
                if (a[i][j] != '.') blocked[j] = true;
            }
        }
        return -1;
    }
    static void Solve()
    {
        var x = cin.ReadInt64() - 2;
        cout.WriteLine(x * x);
    }

    static string[] Tests =
    {
        @"5",
        @"3",
        @"6",
        @"54321"
    };

    static string Generate(int k, int n)
    {
        var sb = new StringWriter();
        var output = new Output(sb);

        output.WriteLine("{0} {1}", k, n);

        return sb.ToString();
    }
    static void Main()
    {
#if DEBUG
        if (Tests.Length == 0)
        {
            Solve();
        }
        else
        {
            foreach(var test in Tests)
            {
                cin = new Input(new StringReader(test));
                Start();
                Solve();
                Stop();
            }
            /*
            for (var i = 0; i <= 10; i++)
            {
                var test = Generate(1, i);
                Start();
                cin = new Input(new StringReader(test));
                Solve();
                Stop();
            }
            //*/
        }
#else
        /*
        cin = new Input(name + ".in");
        cout = new Output(name + ".out");
        //*/
        //Solve();

                var th = new Thread(Solve, 1024 * 1024 * 64);
                th.Start();
                th.Join();
        cout.Flush();
        cout.Dispose();
#endif
    }
}


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

public class E167
{
    public static void Main()
    {
        new E167().Entry();
    }//Main

    void Entry()
    {
        int[] tmp = intSplit(' ');
        int n = tmp[0];
        int m = tmp[1];
        int[] type = new int[n];
        List<int>[] edges = new List<int>[n];
        for (int i = 0; i < n; i++)
            edges[i] = new List<int>();
        for (int i = 0; i < m; i++)
        {
            tmp = intSplit(' ');
            int a = tmp[0] - 1;
            int b = tmp[1] - 1;
            edges[a].Add(b);
            edges[b].Add(a);
        }//for i
        Queue<int> que = new Queue<int>();
        for (int i = 0; i < n; i++)
            que.Enqueue(i);
        while (que.Count!=0)
        {
            int deq = que.Dequeue();
            int cnt = 0;
            foreach (int item in edges[deq])
            {
                if (type[item] == type[deq])
                    cnt++;
            }//foreach item
            if (cnt>=2)
            {
                type[deq] ^= 1;
                foreach (int item in edges[deq])
                {
                    if (type[item] == type[deq])
                        que.Enqueue(item);
                }//foreach item
            }//if
        }//while
        StringBuilder sb = new StringBuilder();
        foreach (int item in type)
        {
            sb.Append(item);
        }//foreach item
        Console.WriteLine(sb.ToString());
    }

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

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

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

    double doubleRead()
    {
        return double.Parse(Console.ReadLine());
    }

    string[] strSplit(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);
    }

    double[] doubleSplit(char a)
    {
        return Array.ConvertAll<string, double>(Console.ReadLine().ToString().Split('a'), double.Parse);
    }

}//Template


using System;
using System.Linq;

namespace Sqare
{
    class Program
    {
        static void Main(string[] args)
        {
            long [] numbers = Console.ReadLine().Split().Select(x => long.Parse(x)).ToArray();
            long tile1, tile2;
            if (numbers[0] % numbers[2] == 0)
            {
                tile1 = numbers[0] / numbers[2];
            }
            else
            {
                tile1 = numbers[0] / numbers[2] + 1;
            }
            if (numbers[1] % numbers[2] == 0)
            {
                tile2 = numbers[1] / numbers[2];
            }
            else
            {
                tile2 = numbers[1] / numbers[2] + 1;
            }
            Console.WriteLine(tile2 * tile1);
        }
    }
}


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

class A
{
    static void Main(string[] args)
    {
#if ONLINE_JUDGE
#else
        Console.SetIn(new StreamReader("in.txt"));
#endif
        string[] read = Console.ReadLine().Split(' ');
        int n = Convert.ToInt32(read[0]);
        int x = Convert.ToInt32(read[1]);
        int y = Convert.ToInt32(read[2]);
        int clones = 0;
        float need = n * ((float)y / 10);
        if (need % 10 > 0) need = need/10+1;
        else need = need / 10;
        if (x < need) clones = (int)need - x;
        Console.WriteLine(clones);
#if ONLINE_JUDGE
#else
        Console.ReadKey();
#endif
    }
}


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

namespace ConsoleApplication1
{
    class Program
    {
        const long mod = 1000000007;
        static long phi(long n)
        {
            if (n == 1)
                return 1;
            long result = n;
            for (long i = 2; i * i <= n; ++i)
                if (n % i == 0)
                {
                    while (n % i == 0)
                        n /= i;
                    result -= result / i;
                }
            if (n > 1)
                result -= result / n;
            return result;
        }

        static void Main()
        {
            string[] token = Console.ReadLine().Split(' ');
            long n = long.Parse(token[0]);
            long k = long.Parse(token[1]);
            long t = 1;
            long ans = n;
            if (k >= n)
            {
                Console.WriteLine(1);
                return;
            }
            else
            {
                if (k >= 71)
                {
                    Console.WriteLine("1");
                    return;
                }
                else
                {
                    while (t <= k)
                    {
                        if (t % 2 == 1)
                        {
                            ans = phi(ans);
                            t++;
                        }
                        else
                        {
                            t++;
                            continue;
                        }
                    }
                }
            }
            Console.WriteLine(ans % mod);
            Console.Read();
        }
    }
}


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

namespace Code
{
    class Program
    {
        static void Main(string[] args)
        {
            string a = Console.ReadLine();
            int n = int.Parse(a.Split(' ')[0]);
            int k = int.Parse(a.Split(' ')[1]);
            string s = Console.ReadLine();
            for (int i = 0; i < s.Length; i++)
            {
                int c = 0;
                for (int j = 0; j < s.Length; j++)
                {
                    if (s[i] == s[j])
                        c++;
                }
                if (c > k)
                {
                    Console.Write("NO");
                    return;
                }
                c = 0;
            }
            Console.WriteLine("YES");

        }
    }
}


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

namespace A.Theatre_Square
{
    class Program
    {

        const double eps = 0.01;

        static int dcmp(double x)
        {
            if (x < -eps) return -1;
            if (x > eps) return 1;
            return 0;
        }

        static void Main(string[] args)
        {
            Int64 data = Int64.Parse(Console.ReadLine().Trim());
            if (data == 0)
            {
                Console.WriteLine("0");
                return;
            }
            Int64 count = 0;
            Int64 n = (Int64)((Math.Sqrt((((double)data * data) - 0.5 * 0.5) / 0.75) + 1) / 2);
            count=3*n*n-3*n+1;

                Int64 need = 0;
                Int64 j = 0;
                do
                {
                    double yy = ( 0.5+n ) * Math.Sqrt(3);
                    double xx = 0.5;
                    need = 0;
                    for (Int64 i = j; i < (n + 1)/2+2; i++)
                    {
                        double x = xx + 1.5 * i;
                        double y = yy - (double)i * Math.Sqrt(3)/2;
                        if (dcmp(x * x + y * y - (double)(data) * data) <= 0)
                        {
                            need = (n + 1 - i * 2) < 0 ? 0 : (n + 1 - i * 2);
                            j = i;
                            break;
                        }
                    }
                    count += need * 6;
                    n++;
                } while (need != 0);

            Console.WriteLine(count);

        }

    }
}


#define Online

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

namespace CF
{
    delegate double F(double x);
    delegate decimal Fdec(decimal x);

    class Program
    {

        static void Main(string[] args)
        {

#if FileIO
            StreamReader sr = new StreamReader("input.txt");
            StreamWriter sw = new StreamWriter("output.txt");
            Console.SetIn(sr);
            Console.SetOut(sw);
#endif

            A();

#if Online
            Console.ReadLine();
#endif

#if FileIO
            sr.Close();
            sw.Close();
#endif
        }

        static void A()
        {
            string[] input = ReadArray(':');
            int h = int.Parse(input[0]);
            int m = int.Parse(input[1]);
            while (true)
            {
                if (m == 59)
                {
                    if (h == 23)
                    {
                        h = 0;
                    }
                    else
                    {
                        h++;
                    }
                    m = 0;
                }
                else
                {
                    m++;
                }
                if (h == (m % 10) * 10 + m / 10)
                {
                    Console.WriteLine((h < 10 ? "0" + h.ToString() : h.ToString()) + ":" + (m < 10 ? "0" + m.ToString() : m.ToString()));
                    return;
                }
            }
        }

        static void B()
        {

        }

        static void C()
        {

        }

        static void D()
        {

        }

        static void E()
        {

        }

        static string[] ReadArray(char sep)
        {
            return Console.ReadLine().Split(sep);
        }

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

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

    public static class MyMath
    {
        public static long BinPow(long a, long n, long mod)
        {
            long res = 1;
            while (n > 0)
            {
                if ((n & 1) == 1)
                {
                    res = (res * a) % mod;
                }
                a = (a * a) % mod;
                n >>= 1;
            }
            return res;
        }

        public static long GCD(long a, long b)
        {
            while (b != 0) b = a % (a = b);
            return a;
        }

        public static int GCD(int a, int b)
        {
            while (b != 0) b = a % (a = b);
            return a;
        }

        public static long LCM(long a, long b)
        {
            return (a * b) / GCD(a, b);
        }

        public static int LCM(int a, int b)
        {
            return (a * b) / GCD(a, b);
        }
    }

    class Edge
    {
        public int a;
        public int b;
        public int w;

        public Edge(int a, int b, int w)
        {
            this.a = a;
            this.b = b;
            this.w = w;
        }
    }

    class Graph
    {
        public List<int>[] g;
        public int[] color; //0-white, 1-gray, 2-black
        public int[] o; //open
        public int[] c; //close
        public int[] p;
        public int[] d;
        public List<Edge> e;
        public Stack<int> ans = new Stack<int>();
        public Graph(int n)
        {
            g = new List<int>[n + 1];
            for (int i = 0; i <= n; i++)
                g[i] = new List<int>();
            color = new int[n + 1];
            o = new int[n + 1];
            c = new int[n + 1];
            p = new int[n + 1];
            d = new int[n + 1];
        }

        const int white = 0;
        const int gray = 1;
        const int black = 2;

        public bool DFS(int u, ref int time)
        {
            color[u] = gray;
            time++;
            o[u] = time;
            for (int i = 0; i < g[u].Count; i++)
            {
                int v = g[u][i];
                if (color[v] == gray)
                {
                    return true;
                }
                if (color[v] == white)
                {
                    p[v] = u;
                    if (DFS(v, ref time)) return true;
                }
            }
            color[u] = black;
            ans.Push(u);
            c[u] = time;
            time++;
            return false;
        }
    }

    static class GraphUtils
    {
        const int white = 0;
        const int gray = 1;
        const int black = 2;

        public static void BFS(int s, Graph g)
        {
            Queue<int> q = new Queue<int>();
            q.Enqueue(s);
            while (q.Count != 0)
            {
                int u = q.Dequeue();
                for (int i = 0; i < g.g[u].Count; i++)
                {
                    int v = g.g[u][i];
                    if (g.color[v] == white)
                    {
                        g.color[v] = gray;
                        g.d[v] = g.d[u] + 1;
                        g.p[v] = u;
                        q.Enqueue(v);
                    }
                }
                g.color[u] = black;
            }
        }

        public static bool DFS(int u, ref int time, Graph g, Stack<int> st)
        {
            g.color[u] = gray;
            time++;
            g.o[u] = time;
            for (int i = 0; i < g.g[u].Count; i++)
            {
                int v = g.g[u][i];
                if (g.color[v] == gray)
                {
                    return true;
                }
                if (g.color[v] == white)
                {
                    g.p[v] = u;
                    if (DFS(v, ref time, g, st)) return true;
                }
            }
            g.color[u] = black;
            st.Push(u);
            g.c[u] = time;
            time++;
            return false;
        }

        public static void FordBellman(int u, Graph g)
        {
            int n = g.g.Length;
            for (int i = 0; i <= n; i++)
            {
                g.d[i] = int.MaxValue;
                g.p[i] = 0;
            }

            g.d[u] = 0;

            for (int i = 0; i < n - 1; i++)
            {
                for (int j = 0; j < g.e.Count; j++)
                {
                    if (g.d[g.e[j].a] != int.MaxValue)
                    {
                        if (g.d[g.e[j].a] + g.e[j].w < g.d[g.e[j].b])
                        {
                            g.d[g.e[j].b] = g.d[g.e[j].a] + g.e[j].w;
                            g.p[g.e[j].b] = g.e[j].a;
                        }
                    }
                }
            }
        }
    }

    static class ArrayUtils
    {
        public static int BinarySearch(int[] a, int val)
        {
            int left = 0;
            int right = a.Length - 1;
            int mid;

            while (left < right)
            {
                mid = left + ((right - left) >> 1);
                if (val <= a[mid])
                {
                    right = mid;
                }
                else
                {
                    left = mid + 1;
                }
            }

            if (a[left] == val)
                return left;
            else
                return -1;
        }

        public static double Bisection(F f, double left, double right, double eps)
        {
            double mid;
            while (right - left > eps)
            {
                mid = left + ((right - left) / 2d);
                if (Math.Sign(f(mid)) != Math.Sign(f(left)))
                    right = mid;
                else
                    left = mid;
            }
            return (left + right) / 2d;
        }

        public static decimal TernarySearchDec(Fdec f, decimal eps, decimal l, decimal r, bool isMax)
        {
            decimal m1, m2;
            while (r - l > eps)
            {
                m1 = l + (r - l) / 3m;
                m2 = r - (r - l) / 3m;
                if (f(m1) < f(m2))
                    if (isMax)
                        l = m1;
                    else
                        r = m2;
                else
                    if (isMax)
                        r = m2;
                    else
                        l = m1;
            }
            return r;
        }

        public static double TernarySearch(F f, double eps, double l, double r, bool isMax)
        {
            double m1, m2;
            while (r - l > eps)
            {
                m1 = l + (r - l) / 3d;
                m2 = r - (r - l) / 3d;
                if (f(m1) < f(m2))
                    if (isMax)
                        l = m1;
                    else
                        r = m2;
                else
                    if (isMax)
                        r = m2;
                    else
                        l = m1;
            }
            return r;
        }

        public static void Merge<T>(T[] A, int p, int q, int r, T[] L, T[] R, Comparison<T> comp)
        {
            for (int i = p; i <= q; i++)
                L[i] = A[i];
            for (int i = q + 1; i <= r; i++)
                R[i] = A[i];

            for (int k = p, i = p, j = q + 1; k <= r; k++)
            {
                if (i > q)
                {
                    for (; k <= r; k++, j++)
                        A[k] = R[j];
                    return;
                }
                if (j > r)
                {
                    for (; k <= r; k++, i++)
                        A[k] = L[i];
                    return;
                }
                if (comp(L[i], R[j]) <= 0)
                {
                    A[k] = L[i];
                    i++;
                }
                else
                {
                    A[k] = R[j];
                    j++;
                }
            }
        }

        public static void Merge_Sort<T>(T[] A, int p, int r, T[] L, T[] R, Comparison<T> comp)
        {
            if (p >= r) return;
            int q = p + ((r - p) >> 1);
            Merge_Sort(A, p, q, L, R, comp);
            Merge_Sort(A, q + 1, r, L, R, comp);
            Merge(A, p, q, r, L, R, comp);
        }

        public static void Merge<T>(T[] A, int p, int q, int r, T[] L, T[] R) where T : IComparable<T>
        {
            for (int i = p; i <= q; i++)
                L[i] = A[i];
            for (int i = q + 1; i <= r; i++)
                R[i] = A[i];

            for (int k = p, i = p, j = q + 1; k <= r; k++)
            {
                if (i > q)
                {
                    for (; k <= r; k++, j++)
                        A[k] = R[j];
                    return;
                }
                if (j > r)
                {
                    for (; k <= r; k++, i++)
                        A[k] = L[i];
                    return;
                }
                if (L[i].CompareTo(R[j]) >= 0)
                {
                    A[k] = L[i];
                    i++;
                }
                else
                {
                    A[k] = R[j];
                    j++;
                }
            }
        }

        public static void Merge_Sort<T>(T[] A, int p, int r, T[] L, T[] R) where T : IComparable<T>
        {
            if (p >= r) return;
            int q = p + ((r - p) >> 1);
            Merge_Sort(A, p, q, L, R);
            Merge_Sort(A, q + 1, r, L, R);
            Merge(A, p, q, r, L, R);
        }

        static void Shake<T>(T[] a)
        {
            Random rnd = new Random(Environment.TickCount);
            T temp;
            int b, c;
            for (int i = 0; i < a.Length; i++)
            {
                b = rnd.Next(0, a.Length);
                c = rnd.Next(0, a.Length);
                temp = a[b];
                a[b] = a[c];
                a[c] = temp;
            }
        }
    }
}


using System;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Text;
using static System.Console;

namespace Olymp
{
  public class ProblemSolver
  {
    private readonly Tokenizer input;

    public void Solve()
    {
      var s = input.ReadToken();
      for (var i = 0; i < s.Length - 1; i++)
      {
        if (!"naouie".Contains(s[i]) &&
            !"aouie".Contains(s[i + 1]))
        {
          Write("NO");
          return;
        }
      }
      if (!"naouie".Contains(s.Last()))
      {
        Write("NO");
        return;
      }
      Write("YES");
    }

    public ProblemSolver(TextReader input)
    {
      this.input = new Tokenizer(input);
    }
  }

  #region Service classes

  public class Tokenizer
  {
    private TextReader reader;

    public string ReadToEnd()
    {
      return this.reader.ReadToEnd();
    }

    public int ReadInt()
    {
      var c = SkipWS();
      if (c == -1)
        throw new EndOfStreamException();
      var isNegative = false;
      if (c == '-' || c == '+')
      {
        isNegative = c == '-';
        c = this.reader.Read();
        if (c == -1)
          throw new EndOfStreamException("Digit expected, but end of stream occurs");
      }
      if (!char.IsDigit((char)c))
        throw new InvalidOperationException($"Digit expected, but was: '{(char)c}'");
      var result = (char)c - '0';
      c = this.reader.Read();
      while (c > 0 && !char.IsWhiteSpace((char)c))
      {
        if (!char.IsDigit((char)c))
          throw new InvalidOperationException($"Digit expected, but was: '{(char)c}'");
        result = result * 10 + (char)c - '0';
        c = this.reader.Read();
      }
      if (isNegative)
        result = -result;
      return result;
    }

    public string ReadLine()
    {
      return reader.ReadLine();
    }

    public long ReadLong()
    {
      return long.Parse(this.ReadToken());
    }

    public double ReadDouble()
    {
      return double.Parse(this.ReadToken(), CultureInfo.InvariantCulture);
    }

    public int[] ReadIntArray(int n)
    {
      var a = new int[n];
      for (var i = 0; i < n; i++)
        a[i] = ReadInt();
      return a;
    }

    public long[] ReadLongArray(int n)
    {
      var a = new long[n];
      for (var i = 0; i < n; i++)
        a[i] = ReadLong();
      return a;
    }

    public double[] ReadDoubleArray(int n)
    {
      var a = new double[n];
      for (var i = 0; i < n; i++)
        a[i] = ReadDouble();
      return a;
    }

    public string ReadToken()
    {
      var c = SkipWS();
      if (c == -1)
        return null;
      var sb = new StringBuilder();
      while (c > 0 && !char.IsWhiteSpace((char)c))
      {
        sb.Append((char)c);
        c = this.reader.Read();
      }
      return sb.ToString();
    }

    private int SkipWS()
    {
      var c = this.reader.Read();
      if (c == -1)
        return c;
      while (c > 0 && char.IsWhiteSpace((char)c))
        c = this.reader.Read();
      return c;
    }

    public Tokenizer(TextReader reader)
    {
      this.reader = reader;
    }
  }

  internal class Program
  {
    public static void Main(string[] args)
    {
      var solver = new ProblemSolver(In);
      solver.Solve();
    }
  }

  #endregion
}


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

namespace Codeforces
{
    class Program : ProgramBase
    {
        private const long commonMod = 1000000007;

        static void Main(string[] args)
        {
            var p = new Program();
            var x = p.Solve();
            p.Out(x);
        }

        object Solve()
        {
            var s = Read();
            var abc = "abcdefghijklmnopqrstuvwxyz";
            var k = 0;
            for (int i = 0; i < s.Length; i++)
            {
                if (abc.IndexOf(s[i]) == k)
                    k++;
                if (abc.IndexOf(s[i]) > k)
                    return "NO";
            }
            return "YES";
        }

        long BS(long n, long m, long k, long left, long right)
        {
            if (right - left == 1)
                return left;
            var half = (right + left) / 2;
            if (Check(n, m, k, half))
                return BS(n, m, k, half, right);
            return BS(n, m, k, left, half);
        }

        bool Check(long n, long m, long k, long value)
        {
            var result = value + (value - 1)*value;
            if (k < value)
                result -= (value - k) * (value - k + 1) / 2;
            if (n - k + 1 < value)
                result -= (value - (n - k + 1)) * (value - (n - k)) / 2;
            return result <= m;
        }

        long FastPow(long b, long pow)
        {
            if (pow == 0)
                return 1;
            if (pow == 1)
                return b;
            if (pow % 2 == 0)
                return FastPow(b * b, pow / 2);
            return b * FastPow(b, pow - 1);
        }

        bool IsPrime(int n)
        {
            for (int i = 2; i <= Math.Sqrt(n); i++)
            {
                if (n % i == 0)
                    return false;
            }
            return true;
        }
    }

    abstract class ProgramBase
    {
        bool? prod = null;
        StreamReader f;
        Queue<string> tokens;
        protected string FileName { private get; set; }

        protected string Read()
        {
            if (f == null)
                f = string.IsNullOrEmpty(FileName)
                    ? new StreamReader(Console.OpenStandardInput())
                    : new StreamReader((GetProd() ? "" : "c:\\dev\\") + FileName);
            return f.ReadLine();
        }

        protected string ReadToken()
        {
            if (tokens == null || tokens.Count == 0)
                tokens = new Queue<string>(Read().Split(' '));
            return tokens.Dequeue();
        }

        protected long ReadLong() { return long.Parse(ReadToken()); }

        protected long[] ReadLongs()
        {
            var s = Read();
            if (s == "")
                return new long[0];
            var tokens = s.Split(' ');
            var result = new long[tokens.Length];
            for (int i = 0; i < tokens.Length; i++)
                result[i] = long.Parse(tokens[i]);
            return result;
        }

        public void Out(object r)
        {
            if (string.IsNullOrEmpty(FileName))
                Console.WriteLine(r);
            else if (GetProd())
                File.WriteAllText(FileName, r.ToString());
            else
                Console.WriteLine(r);
        }

        private bool GetProd()
        {

            if (!prod.HasValue)
                try
                {
                    prod = Environment.MachineName != "RENADEEN-W7";
                }
                catch (Exception)
                {
                    prod = true;
                }
            return prod.Value;
        }
    }

    public static class Huj
    {
        public static T MinBy<T>(this IEnumerable<T> source, Func<T, double> func) where T : class
        {
            T result = null;
            var min = double.MaxValue;
            foreach (var item in source)
            {
                var current = func(item);
                if (min > current)
                {
                    min = current;
                    result = item;
                }
            }
            return result;
        }

        public static T MaxBy<T>(this IEnumerable<T> source, Func<T, double> func, T defaultValue = default(T))
        {
            T result = defaultValue;
            var max = double.MinValue;
            foreach (var item in source)
            {
                var current = func(item);
                if (max < current)
                {
                    max = current;
                    result = item;
                }
            }
            return result;
        }

        public static string JoinStrings(this IEnumerable<string> s, string d) { return string.Join(d, s.ToArray()); }

        public static string JoinStrings(this IEnumerable<int> s, string d) { return s.Select(x => x.ToString()).JoinStrings(d); }
        public static string JoinStrings(this IEnumerable<long> s, string d) { return s.Select(x => x.ToString()).JoinStrings(d); }
    }
}


using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Linq;

namespace Temp
{
    struct PointInt
    {
        public long X;

        public long Y;

        public PointInt(long x, long y)
            : this()
        {
            this.X = x;
            this.Y = y;
        }

        public static PointInt operator +(PointInt a, PointInt b)
        {
            return new PointInt(a.X + b.X, a.Y + b.Y);
        }

        public static PointInt operator -(PointInt a, PointInt b)
        {
            return new PointInt(a.X - b.X, a.Y - b.Y);
        }

        public static PointInt operator *(PointInt a, long k)
        {
            return new PointInt(k * a.X, k * a.Y);
        }

        public static PointInt operator *(long k, PointInt a)
        {
            return new PointInt(k * a.X, k * a.Y);
        }

        public bool IsInsideRectangle(long l, long b, long r, long t)
        {
            return (l <= X) && (X <= r) && (b <= Y) && (Y <= t);
        }
    }

    struct LineInt
    {
        public LineInt(PointInt a, PointInt b)
            : this()
        {
            A = a.Y - b.Y;
            B = b.X - a.X;
            C = a.X * b.Y - a.Y * b.X;
        }

        public long A, B, C;

        public bool ContainsPoint(PointInt p)
        {
            return A * p.X + B * p.Y + C == 0;
        }
    }

    class MatrixInt
    {
        private long[,] m_Matrix;

        public int Size
        {
            get
            {
                return m_Matrix.GetLength(0) - 1;
            }
        }

        public long Mod { get; private set; }

        public MatrixInt(int size, long mod = 0)
        {
            m_Matrix = new long[size + 1, size + 1];
            Mod = mod;
        }

        public MatrixInt(long[,] matrix, long mod = 0)
        {
            this.m_Matrix = matrix;
            Mod = mod;
        }

        public static MatrixInt GetIdentityMatrix(int size, long mod = 0)
        {
            long[,] matrix = new long[size + 1, size + 1];

            for (int i = 1; i <= size; i++)
            {
                matrix[i, i] = 1;
            }

            return new MatrixInt(matrix, mod);
        }

        public long this[int i, int j]
        {
            get
            {
                return m_Matrix[i, j];
            }

            set
            {
                m_Matrix[i, j] = value;
            }
        }

        public static MatrixInt operator +(MatrixInt a, MatrixInt b)
        {
            int n = a.Size;
            long mod = Math.Max(a.Mod, b.Mod);
            long[,] c = new long[n, n];
            for (int i = 1; i <= n; i++)
            {
                for (int j = 1; j <= n; j++)
                {
                    c[i, j] = a[i, j] + b[i, j];
                }
            }

            if (mod > 0)
            {
                for (int i = 1; i <= n; i++)
                {
                    for (int j = 1; j <= n; j++)
                    {
                        c[i, j] %= mod;
                    }
                }
            }

            return new MatrixInt(c, mod);
        }

        public static MatrixInt operator *(MatrixInt a, MatrixInt b)
        {
            int n = a.Size;
            long mod = Math.Max(a.Mod, b.Mod);

            long[,] c = new long[n, n];

            for (int i = 1; i <= n; i++)
            {
                for (int j = 1; j <= n; j++)
                {
                    for (int k = 1; k <= n; k++)
                    {
                        c[i, j] += a[i, k] * b[k, j];
                        if (mod > 0)
                        {
                            c[i, j] %= mod;
                        }
                    }
                }
            }

            return new MatrixInt(c, mod);
        }
    }

    static class Algebra
    {
        public static long Phi(long n)
        {
            long result = n;
            for (long i = 2; i * i <= n; i++)
            {
                if (n % i == 0)
                {
                    while (n % i == 0)
                    {
                        n /= i;
                    }

                    result -= result / i;
                }
            }

            if (n > 1)
            {
                result -= result / n;
            }

            return result;
        }

        public static long BinPower(long a, long n, long mod)
        {
            long result = 1;

            while (n > 0)
            {
                if ((n & 1) != 0)
                {
                    result = (result * a) % mod;
                }

                a = (a * a) % mod;
                n >>= 1;
            }

            return result;
        }

        public static class Permutations
        {
            public static int[] GetRandomPermutation(int n)
            {
                int[] p = new int[n];
                for (int i = 0; i < n; i++)
                {
                    p[i] = i;
                }

                Random random = new Random();
                for (int i = n - 1; i > 0; i--)
                {
                    int j = random.Next(i + 1);
                    int tmp = p[i];
                    p[i] = p[j];
                    p[j] = tmp;
                }

                return p;
            }
        }

        public static T[] Shuffle<T>(this T[] array)
        {
            int length = array.Length;
            int[] p = Permutations.GetRandomPermutation(length);
            T[] result = new T[length];
            for (int i = 0; i < length; i++)
            {
                result[i] = array[p[i]];
            }

            return result;
        }

        public static MatrixInt MatrixBinPower(MatrixInt a, long n)
        {
            MatrixInt result = new MatrixInt(a.Size);

            while (n > 0)
            {
                if ((n & 1) != 0)
                {
                    result *= a;
                }

                a *= a;
                n >>= 1;
            }

            return result;
        }

        public static long Gcd(long a, long b)
        {
            return b == 0 ? a : Gcd(b, a % b);
        }

        public static long ExtendedGcd(long a, long b, out long x, out long y)
        {
            if (b == 0)
            {
                x = 1;
                y = 0;
                return a;
            }

            long x1;
            long y1;
            long d = ExtendedGcd(b, a % b, out x1, out y1);
            x = y1;
            y = x1 - (a / b) * y1;
            return d;
        }

        public static long Lcm(long a, long b)
        {
            return (a / Gcd(a, b)) * b;
        }

        public static bool[] GetPrimes(int n)
        {
            n = Math.Max(n, 2);
            bool[] prime = new bool[n + 1];
            for (int i = 2; i <= n; i++)
            {
                prime[i] = true;
            }

            for (int i = 2; i * i <= n; i++)
            {
                if (prime[i])
                {
                    if ((long)i * i <= n)
                    {
                        for (int j = i * i; j <= n; j += i)
                        {
                            prime[j] = false;
                        }
                    }
                }
            }

            return prime;
        }

        public static long GetFibonacciNumber(long n, long mod = 0)
        {
            long[,] matrix = new long[,] { { 0, 0, 0 }, { 0, 0, 1 }, { 0, 1, 1 } };

            MatrixInt result = MatrixBinPower(new MatrixInt(matrix, mod), n);

            return result[2, 2];
        }

        public static long[] GetFibonacciSequence(int n)
        {
            long[] result = new long[n];
            result[0] = result[1] = 1;

            for (int i = 2; i < n; i++)
            {
                result[i] = result[i - 1] + result[i - 2];
            }

            return result;
        }

        public static long GetInverseElement(long a, long mod)
        {
            long x, y;
            long g = ExtendedGcd(a, mod, out x, out y);

            if (g != 1)
            {
                return -1;
            }

            return ((x % mod) + mod) % mod;
        }

        public static long[] GetAllInverseElements(long mod)
        {
            long[] result = new long[mod];
            result[1] = 1;
            for (int i = 2; i < mod; i++)
            {
                result[i] = (mod - (((mod / i) * result[mod % i]) % mod)) % mod;
            }

            return result;
        }
    }

    internal static class Reader
    {
        public static void ReadInt(out int a)
        {
            int[] number = new int[1];
            ReadInt(number);
            a = number[0];
        }

        public static void ReadInt(out int a, out int b)
        {
            int[] numbers = new int[2];
            ReadInt(numbers);
            a = numbers[0];
            b = numbers[1];
        }

        public static void ReadInt(out int int1, out int int2, out int int3)
        {
            int[] numbers = new int[3];
            ReadInt(numbers);
            int1 = numbers[0];
            int2 = numbers[1];
            int3 = numbers[2];
        }

        public static void ReadInt(out int int1, out int int2, out int int3, out int int4)
        {
            int[] numbers = new int[4];
            ReadInt(numbers);
            int1 = numbers[0];
            int2 = numbers[1];
            int3 = numbers[2];
            int4 = numbers[3];
        }

        public static void ReadLong(out long a)
        {
            long[] number = new long[1];
            ReadLong(number);
            a = number[0];
        }

        public static void ReadLong(out long a, out long b)
        {
            long[] numbers = new long[2];
            ReadLong(numbers);
            a = numbers[0];
            b = numbers[1];
        }

        public static void ReadLong(out long int1, out long int2, out long int3)
        {
            long[] numbers = new long[3];
            ReadLong(numbers);
            int1 = numbers[0];
            int2 = numbers[1];
            int3 = numbers[2];
        }

        public static void ReadLong(out long int1, out long int2, out long int3, out long int4)
        {
            long[] numbers = new long[4];
            ReadLong(numbers);
            int1 = numbers[0];
            int2 = numbers[1];
            int3 = numbers[2];
            int4 = numbers[3];
        }

        public static void ReadInt(int[] numbers)
        {
            // ReSharper disable PossibleNullReferenceException
            var list = Console.ReadLine().Split();
            // ReSharper restore PossibleNullReferenceException

            int count = Math.Min(numbers.Length, list.Length);

            for (int i = 0; i < count; i++)
            {
                numbers[i] = int.Parse(list[i]);
            }
        }

        public static int[] ReadDigits()
        {
            // ReSharper disable AssignNullToNotNullAttribute
            return Console.ReadLine().Select(x => int.Parse(x.ToString())).ToArray();
            // ReSharper restore AssignNullToNotNullAttribute
        }

        public static void ReadLong(long[] numbers)
        {
            // ReSharper disable PossibleNullReferenceException
            var list = Console.ReadLine().Split();
            // ReSharper restore PossibleNullReferenceException

            int count = Math.Min(numbers.Length, list.Length);

            for (int i = 0; i < count; i++)
            {
                numbers[i] = long.Parse(list[i]);
            }
        }

        public static void ReadDouble(double[] numbers)
        {
            // ReSharper disable PossibleNullReferenceException
            var list = Console.ReadLine().Split();
            // ReSharper restore PossibleNullReferenceException

            int count = Math.Min(numbers.Length, list.Length);

            for (int i = 0; i < count; i++)
            {
                numbers[i] = double.Parse(list[i]);
            }
        }

        public static void ReadDouble(out double a, out double b)
        {
            double[] numbers = new double[2];
            ReadDouble(numbers);
            a = numbers[0];
            b = numbers[1];
        }

        public static void ReadDouble(out double int1, out double int2, out double int3)
        {
            double[] numbers = new double[3];
            ReadDouble(numbers);
            int1 = numbers[0];
            int2 = numbers[1];
            int3 = numbers[2];
        }

        public static string ReadLine()
        {
            return Console.ReadLine();
        }
    }

    static class MyMath
    {
        public static int GetMinimalPrimeDivisor(int n)
        {
            for (int i = 2; i * i <= n; i++)
            {
                if (n % i == 0)
                {
                    return i;
                }
            }

            return n;
        }

        public static long Sqr(long x)
        {
            return x * x;
        }
    }

    public interface IGraph
    {
        int Vertices  { get; set; }

        IList<int> this[int i] { get; }

        void AddEdge(int u, int v);

        void AddOrientedEdge(int u, int v);
    }

    public class Graph : IGraph
    {
        private List<int>[] m_Edges;

        public int Vertices { get; set; }

        public IList<int> this[int i]
        {
            get
            {
                return this.m_Edges[i];
            }
        }

        public Graph(int vertices)
        {
            this.Vertices = vertices;

            this.m_Edges = new List<int>[vertices];

            for (int i = 0; i < vertices; i++)
            {
                this.m_Edges[i] = new List<int>();
            }
        }

        public void AddEdge(int u, int v)
        {
            this.AddOrientedEdge(u, v);
            this.AddOrientedEdge(v, u);
        }

        public void AddOrientedEdge(int first, int second)
        {
            this.m_Edges[first].Add(second);
        }

        public int[] Bfs(int start)
        {
            int[] d = new int[Vertices];
            for (int i = 0; i < Vertices; i++)
            {
                d[i] = -1;
            }

            Queue<int> queue = new Queue<int>();
            queue.Enqueue(start);
            d[start] = 0;

            while (queue.Count > 0)
            {
                int v = queue.Dequeue();
                foreach (int t in this.m_Edges[v].Where(t => d[t] == -1))
                {
                    queue.Enqueue(t);
                    d[t] = d[v] + 1;
                }
            }

            return d;
        }
    }

    class SimpleSumTable
    {
        private readonly int[,] m_Sum;

        public SimpleSumTable(int n, int m, int[,] table)
        {
            m_Sum = new int[n + 1, m + 1];

            for (int i = 1; i < n + 1; i++)
            {
                for (int j = 1; j < m + 1; j++)
                {
                    m_Sum[i, j] = m_Sum[i, j - 1] + m_Sum[i - 1, j] - m_Sum[i - 1, j - 1] + table[i, j];
                }
            }
        }

        public int GetSum(int l, int b, int r, int t)
        {
            return m_Sum[r, t] - m_Sum[r, b] - m_Sum[l, t] + m_Sum[l, b];
        }
    }

    class SegmentTreeSimpleInt<T>
    {
        public int Size { get; private set; }

        private readonly T[] m_Tree;

        private Func<T, T, T> m_Operation;

        private T m_Null;

        public SegmentTreeSimpleInt(int size, Func<T, T, T> operation, T nullElement, IList<T> array = null)
        {
            this.Size = size;
            this.m_Operation = operation;
            this.m_Null = nullElement;

            m_Tree = new T[4 * size];
            if (array != null)
            {
                this.Build(array, 1, 0, size - 1);
            }
        }

        private void Build(IList<T> array, int v, int tl, int tr)
        {
            if (tl == tr)
            {
                m_Tree[v] = array[tl];
            }
            else
            {
                int tm = (tl + tr) / 2;
                this.Build(array, 2 * v, tl, tm);
                this.Build(array, 2 * v + 1, tm + 1, tr);
                this.CalculateNode(v);
            }
        }

        public T GetSum(int l, int r)
        {
            return GetSum(1, 0, Size - 1, l, r);
        }

        private T GetSum(int v, int tl, int tr, int l, int r)
        {
            if (l > r)
            {
                return m_Null;
            }

            if (l == tl && r == tr)
            {
                return m_Tree[v];
            }

            int tm = (tl + tr) / 2;

            return this.m_Operation(GetSum(2 * v, tl, tm, l, Math.Min(r, tm)),GetSum(2 * v + 1, tm + 1, tr, Math.Max(l, tm + 1), r));
        }

        public void Update(int pos, T newValue)
        {
            Update(1, 0, Size - 1, pos, newValue);
        }

        private void Update(int v, int tl, int tr, int pos, T newValue)
        {
            if (tl == tr)
            {
                m_Tree[v] = newValue;
            }
            else
            {
                int tm = (tl + tr) / 2;
                if (pos <= tm)
                {
                    Update(2 * v, tl, tm, pos, newValue);
                }
                else
                {
                    Update(2 * v + 1, tm + 1, tr, pos, newValue);
                }
                this.CalculateNode(v);
            }
        }

        private void CalculateNode(int v)
        {
            m_Tree[v] = this.m_Operation(m_Tree[2 * v], m_Tree[2 * v + 1]);
        }
    }

    struct Pair<TFirst, TSecond>
    {
        public Pair(TFirst first, TSecond second)
            : this()
        {
            this.First = first;
            this.Second = second;
        }

        public TFirst First { set; get; }

        public TSecond Second { set; get; }
    }

    class Program
    {
        private static StreamReader m_InputStream;

        private static StreamWriter m_OutStream;

        private static void OpenFiles()
        {
            m_InputStream = File.OpenText("input.txt");
            Console.SetIn(m_InputStream);

            m_OutStream = File.CreateText("output.txt");
            Console.SetOut(m_OutStream);
        }

        private static void CloseFiles()
        {
            m_OutStream.Flush();

            m_InputStream.Dispose();
            m_OutStream.Dispose();
        }

        static void Main()
        {
            //OpenFiles();

            new Solution().Solve();

            //CloseFiles();
        }
    }

    internal class Solution
    {
        private int[,,,] pos;

        private Card[] cards;

        public void Solve()
        {
            int n;
            Reader.ReadInt(out n);

            cards = new Card[n];

            string s = Reader.ReadLine();
            var split = s.Split();
            for (int i = 0; i < n; i++)
            {
                cards[i] = new Card(split[i], i);
            }

            pos = new int[n + 1,n,n,n];

            Console.Write(this.IsPossible(n, n - 3, n - 2, n - 1) == 1 ? "YES" : "NO");
        }

        private int IsPossible(int n, int a, int b, int c)
        {
            if (n == 1)
            {
                return 1;
            }

            if (n == 2)
            {
                return this.Compatible(cards[b], cards[c]) ? 1 : 2;
            }

            if (pos[n, a, b, c] != 0)
            {
                return pos[n, a, b, c];
            }

            if (this.Compatible(cards[b], cards[c]) && this.IsPossible(n - 1, n - 4, a, c) == 1 ||
                n > 3 && this.Compatible(cards[n - 4], cards[c]) && this.IsPossible(n - 1, c, a, b) == 1)
            {
                pos[n, a, b, c] = 1;
                return 1;
            }
            else
            {
                pos[n, a, b, c] = 2;
                return 2;
            }
        }

        class Card
        {
            public Card(string card, int id)
            {
                Value = card[0];
                Suit = card[1];
                Id = id;
            }

            public char Value;

            public char Suit;

            public int Id;
        }

        private bool Compatible(Card a, Card b)
        {
            return a.Value == b.Value || a.Suit == b.Suit;
        }
    }
}


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

namespace ConsoleApplication41
{
    class Program
    {
        static void Main(string[] args)
        {
            List<string> strList = new List<string>();
            strList.Add("espeon");
            strList.Add("vaporeon");
            strList.Add("jolteon");
            strList.Add("flareon");
            strList.Add("umbreon");
            strList.Add("leafeon");
            strList.Add("glaceon");
            strList.Add("sylveon");
            string temp;
            string str = "j......";
            int n = 0,n2=0, mayor=0;

            int t = Convert.ToInt32(Console.ReadLine());
            str = Console.ReadLine();

            if (str!="......"&&str!="........")
            {
                for (int x = 0; x < strList.Count; x++)
                {
                    temp = strList[x];
                    n = 0;

                    if (temp.Length >= str.Length)
                    {
                        //Console.WriteLine(temp.Length + " " + str.Length);
                        for (int y = 0; y < str.Length; y++)
                        {
                            if (temp[y] == str[y])
                            {
                                //Console.WriteLine(temp[y] + " " + str[y]);
                                n++;
                            }

                        }
                    }
                    if (n > mayor)
                    {
                        mayor = n;
                        n2 = x;
                    }
                }
                Console.WriteLine(strList[n2]);
            }
            else
            {
                for (int x = 0; x < strList.Count; x++)
                {
                    temp = strList[x];
                    if (temp.Length ==t)
                    {
                        Console.WriteLine(temp);
                    }
                }
            }

            Console.ReadLine();

        }
    }
}


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

namespace Dreamoon_and_Stairs
{
    class Program
    {
        static void Main(string[] args)
        {
            string str_Inputs = Console.ReadLine();
            string[] arr_Inputs = str_Inputs.Split(' ');
            int n = Convert.ToInt32(arr_Inputs[0]);
            int m = Convert.ToInt32(arr_Inputs[1]);

            int min = n / 2 + n%2;
            int max = n;

            for (int i = min; i <= max; i++)
            {
                if (i % m == 0)
                {
                    Console.Write(i);
                    return;
                }
            }
            Console.Write("-1");
        }
    }
}


using System;
using System.Linq;
using System.Diagnostics;
using System.Collections.Generic;
using Debug = System.Diagnostics.Debug;
using StringBuilder = System.Text.StringBuilder;
using System.Numerics;

namespace Program
{

    public class Solver
    {
        public void Solve()
        {
            var table = new CombinationTable(300050);
            var a = sc.Integer();
            var b = sc.Integer();
            var c = sc.Integer();
            var l = sc.Integer();
            long all = 0;
            for (int i = 0; i <= l; i++)
            {
                all += table[i + 2, 2];
                Debug.WriteLine(all);
            }
            var abc = new int[] { a, b, c };
            var sum = a + b + c;
            for (int i = 0; i < 3; i++)
            {
                for (int j = 0; j <= l; j++)
                {
                    var max = abc[i] + j;
                    var rem = Math.Min(l - j, max - sum + abc[i]);
                    if (rem < 0) continue;
                    all -= table[rem + 2, 2];
                }
            }
            IO.Printer.Out.WriteLine(all);
        }
        public IO.StreamScanner sc = new IO.StreamScanner(Console.OpenStandardInput());
        static T[] Enumerate<T>(int n, Func<int, T> f) { var a = new T[n]; for (int i = 0; i < n; ++i) a[i] = f(i); return a; }
        static public void Swap<T>(ref T a, ref T b) { var tmp = a; a = b; b = tmp; }
    }
}

#region main
static class Ex
{
    static public string AsString(this IEnumerable<char> ie) { return new string(System.Linq.Enumerable.ToArray(ie)); }
    static public string AsJoinedString<T>(this IEnumerable<T> ie, string st = " ") { return string.Join(st, ie); }
    static public void Main()
    {
        var solver = new Program.Solver();
        solver.Solve();
        Program.IO.Printer.Out.Flush();
    }
}
#endregion
#region Ex
namespace Program.IO
{
    using System.IO;
    using System.Text;
    using System.Globalization;
    public class Printer : StreamWriter
    {
        static Printer() { Out = new Printer(Console.OpenStandardOutput()) { AutoFlush = false }; }
        public static Printer Out { get; set; }
        public override IFormatProvider FormatProvider { get { return CultureInfo.InvariantCulture; } }
        public Printer(System.IO.Stream stream) : base(stream, new UTF8Encoding(false, true)) { }
        public Printer(System.IO.Stream stream, Encoding encoding) : base(stream, encoding) { }
        public void Write<T>(string format, T[] source) { base.Write(format, source.OfType<object>().ToArray()); }
        public void WriteLine<T>(string format, T[] source) { base.WriteLine(format, source.OfType<object>().ToArray()); }
    }
    public class StreamScanner
    {
        public StreamScanner(Stream stream) { str = stream; }
        public readonly Stream str;
        private readonly byte[] buf = new byte[1024];
        private int len, ptr;
        public bool isEof = false;
        public bool IsEndOfStream { get { return isEof; } }
        private byte read()
        {
            if (isEof) return 0;
            if (ptr >= len) { ptr = 0; if ((len = str.Read(buf, 0, 1024)) <= 0) { isEof = true; return 0; } }
            return buf[ptr++];
        }
        public char Char() { byte b = 0; do b = read(); while ((b < 33 || 126 < b) && !isEof); return (char)b; }

        public string Scan()
        {
            var sb = new StringBuilder();
            for (var b = Char(); b >= 33 && b <= 126; b = (char)read())
                sb.Append(b);
            return sb.ToString();
        }
        public string ScanLine()
        {
            var sb = new StringBuilder();
            for (var b = Char(); b != '\n'; b = (char)read())
                if (b == 0) break;
                else if (b != '\r') sb.Append(b);
            return sb.ToString();
        }
        public long Long()
        {
            if (isEof) return long.MinValue;
            long ret = 0; byte b = 0; var ng = false;
            do b = read();
            while (b != '-' && (b < '0' || '9' < b));
            if (b == '-') { ng = true; b = read(); }
            for (; true; b = read())
            {
                if (b < '0' || '9' < b)
                    return ng ? -ret : ret;
                else ret = ret * 10 + b - '0';
            }
        }
        public int Integer() { return (isEof) ? int.MinValue : (int)Long(); }
        public double Double() { return double.Parse(Scan(), CultureInfo.InvariantCulture); }
        private T[] enumerate<T>(int n, Func<T> f)
        {
            var a = new T[n];
            for (int i = 0; i < n; ++i) a[i] = f();
            return a;
        }

        public char[] Char(int n) { return enumerate(n, Char); }
        public string[] Scan(int n) { return enumerate(n, Scan); }
        public double[] Double(int n) { return enumerate(n, Double); }
        public int[] Integer(int n) { return enumerate(n, Integer); }
        public long[] Long(int n) { return enumerate(n, Long); }
    }
}
#endregion

#region CombinationTable
public class CombinationTable
{
    long[][] nCr;
    public CombinationTable(int n)
    {
        nCr = new long[n + 1][];
        for (int i = 0; i <= n; i++)
            nCr[i] = new long[4];
        nCr[0][0] = 1;
        for (int i = 0; i <= n; i++)
        {
            nCr[i][0] = 1;
            for (int j = 1; j < Math.Min(i + 1, 4); j++)
                nCr[i][j] = (nCr[i - 1][j - 1] + nCr[i - 1][j]);// % mod;
        }
    }
    public long this[int n, int r]
    {
        get
        {
            if (n < 0 || n > nCr.Length)
                return 0;
            if (r < 0 || r > n)
                return 0;
            return nCr[n][r];
        }
    }
    public long RepeatedCombination(int n, int k)
    {
        if (k == 0) return 1;
        return this[n + k - 1, k];
    }
}
#endregion


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

class Program
    {
static void Main()
{

              string [] inputs = Console.ReadLine().Split(' ');
            int l = int.Parse(inputs[0]);
            int r = int.Parse(inputs[1]);
            char[] tempnum;
            List<int> Digits = new List<int>();
            int flag = 0;

            for (int i = l; i <= r; i++)
            {
                tempnum = i.ToString().ToCharArray();
                for (int j = 0; j < tempnum.Length; j++)
                {
                    if (!Digits.Contains(int.Parse(tempnum[j].ToString())))
                    {
                        Digits.Add(int.Parse(tempnum[j].ToString()));
                    }
                }
                if (Digits.Count == tempnum.Length)
                {
                    Console.WriteLine(tempnum);
                    flag = 1;
                    break;
                }
                else { flag = 0; Digits.Clear(); }
            }

            if (flag == 0)
            {
                Console.WriteLine("-1");
            }
}

}


using System;

namespace SortingAlgorithms
{
    class Program
    {
        static void Main(string[] args)
        {
            FriendMeeting();
        }
        public static void FriendMeeting()
        {
            int count;
            int[] arr = Array.ConvertAll(Console.ReadLine().Split(' '), arrTemp => Convert.ToInt32(arrTemp));
            for (int i = 1; i < arr.Length; i++)
            {
                int next = arr[i];
                int j = i - 1;
                while (j >= 0 && arr[j] > next)
                {
                    arr[j + 1] = arr[j];
                    --j;
                }

                arr[j + 1] = next;
            }

            count = (arr[2] - arr[1]) + (arr[1] - arr[0]);
            Console.WriteLine(count);
        }

    }
}


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

namespace timusCsharp
{
    public class Cup
    {
        public int w;
        public int c;
    }
    public class CupCennostComparer: IComparer<Cup>
    {
        public int Compare(Cup A, Cup B)
        {
            if  (A.c < B.c) return 1;
            if (A.c == B.c)
            {
                if (A.w < B.w)
                    return -1;
                else if (A.w == B.w)
                    return 0;
                else if (A.w > B.w)
                    return 1;
            }
            return -1;
        }
    }
    static class Program
    {
        static void Main()
        {
            var s = Console.ReadLine().Split();
            var n = int.Parse(s[0]);
            var m = int.Parse(s[1]);
            var d = int.Parse(s[2]);
            var F = new List<Cup>();
            for (int i = 0; i < n; i++)
            {
                s = Console.ReadLine().Split();
                F.Add(new Cup{ w = int.Parse(s[1]), c = int.Parse(s[0])});
            }
            var I = new List<Cup>();
            for (int i = 0; i < m; i++)
            {
                s = Console.ReadLine().Split();
                I.Add(new Cup { w = int.Parse(s[1]), c = int.Parse(s[0]) });
            }
            var comp = new CupCennostComparer();
            F.Sort(comp);
            I.Sort(comp);
            long sumC = 0;
            if (F[0].w <= d)
            {
                d -= F[0].w;
                sumC += F[0].c;
            }
            else
            {
                Console.WriteLine(0);
                return;
            }
            if (I[0].w <= d)
            {
                d -= I[0].w;
                sumC += I[0].c;
            }
            else
            {
                Console.WriteLine(0);
                return;
            }

            int fIndex = 1;
            int iIndex = 1;

            long maxC = sumC;
            while (fIndex < n && d - F[fIndex].w>= 0)
            {
                d -= F[fIndex].w;
                sumC+=F[fIndex].c;
                fIndex++;
            }
            while (iIndex < m && d - I[iIndex].w >= 0)
            {
                d -= I[iIndex].w;
                sumC += I[iIndex].c;
                iIndex++;
            }
            maxC = Math.Max(sumC, maxC);
            while (fIndex > 1)
            {
                fIndex--;
                d += F[fIndex].w;
                sumC -= F[fIndex].c;
                while (iIndex < m && d - I[iIndex].w >= 0)
                {
                    d -= I[iIndex].w;
                    sumC += I[iIndex].c;
                    iIndex++;
                }
                maxC = Math.Max(sumC, maxC);
            }
            Console.WriteLine(maxC);
        }
    }
}


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

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
             //int n=int.Parse(Console.ReadLine());
             //string[]y=Console.ReadLine().Split(' ');
             int n=int.Parse(Console.ReadLine());
             int g=0;
             int h=0;
             int i=0;
             while(true)
             {
                  if(i%2==0)
                  {
                       h++;
                       g+=2;
                  }
                  else
                  {
                       h++;
                       g++;
                  }
                  i++;
                  if(g>=n)
                  break;
             }
             Console.WriteLine(h);
        }

    }
}


using System;
using System.Linq;
namespace codeforces
{
    class Program
    {
        static void Main(string[] args)
        {
            int t = int.Parse(Console.ReadLine());
            string time = Console.ReadLine();
            if (time.Contains('7'))
            {
                Console.WriteLine(0);
                return;
            }
            int[] nk = time.Split().Select(x => int.Parse(x)).ToArray();
            int rez = 0;
            while (nk[0] % 10 != 7 && nk[1] % 10 != 7)
            {
                rez++;
                if ((nk[1]-=t) < 0)
                {
                    nk[1] += 60;
                    if (--nk[0] < 0)
                        nk[0] += 24;
                }
            }
            Console.WriteLine(rez);
        }
    }
}


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

namespace Olympiads
{
    class Program
    {
        static void Main(string[] args)
        {
            int t = Convert.ToInt32(Console.ReadLine());
            int[] ret = new int[t];
            for (int i = 0; i < t; i++)
            {
                string t2 = Console.ReadLine();
                string[] temp1 = t2.Split(' ');
                int n = Convert.ToInt32(temp1[0]), k = Convert.ToInt32(temp1[1]), d = Convert.ToInt32(temp1[2]);
                string inp = Console.ReadLine();
                string[] temp2 = inp.Split(' ');
                int[] srav = new int[d];
                int y = 0,z = 0;
                for (int j = 0; j < d; j++)
                {
                    srav[j] = Convert.ToInt32(temp2[j]);
                }
                y = Test(srav, k);
                for (int j = d; j < n; j++)
                {
                    if (z > d-1)
                    {
                        z = 0;
                    }
                    srav[z] = Convert.ToInt32(temp2[j]);
                    z++;
                    if (y > Test(srav,k))
                    {
                        y = Test(srav, k);
                    }
                }
                ret[i] = y;
            }
            for (int i = 0; i < t; i++)
            {
                Console.WriteLine(ret[i]);
            }

        }
        static int Test(int[] testing, int k)
        {
            int ret = 0;
            int[] a = new int[k];
            for (int i = 0; i < testing.Length; i++)
            {
                a[testing[i]-1]++;
            }
            for (int i = 0; i < a.Length; i++)
            {
                if (a[i]>0)
                {
                    ret++;
                }
            }
            return ret;
        }
    }
}


using System;
using System.Collections;
using System.Collections.Generic;
class solution
{
    static void Main(string[] args)
    {
        string[] ab = Console.ReadLine().Split(' ');
        int a = Convert.ToInt32(ab[0]);
        int b = Convert.ToInt32(ab[1]);
        if (a == 9 && b == 1) Console.Write(9 + " " + 10);
        else if (a>b || Math.Abs(a - b) > 1) Console.Write("-1");
        else
        {
            if (a == b)
            {
                int val = (a * 10) + 1;
                Console.Write(a * 10 + " " + val);
            }
            else
            {
                int val = a * 100 + 99;
                Console.Write(val + " " + b * 100);
            }
        }
    }
}


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

namespace E
{
    class Program
    {
        static void Main(string[] args)
        {
#if !ONLINE_JUDGE
            Console.SetIn(new System.IO.StreamReader(@"..\..\..\in"));
            Console.SetOut(new System.IO.StreamWriter(@"..\..\..\out"));
            for (int testN = 0; testN < 3; testN++)
            {
#endif
                var n = NextLong();
                var a = new long[64];
                var i2s = new long[64];
                a[0] = 0;
                a[1] = 1;
                a[2] = 4;
                i2s[0] = 1;
                i2s[1] = 2;
                i2s[2] = 4;
                long i2 = 4;
                for (int i = 3; i < 64; i++)
                {
                    a[i] = a[i - 1] * 2 - i2;
                    i2 *= 2;
                    i2s[i] = i2;
                    a[i] += i2;
                }
                long res = 0;
                int x = 0;
                n--;
                while (n > 0)
                {
                    if ((n & 1) == 1)
                    {
                        res += a[x] + i2s[x];
                    }
                    n >>= 1;
                    x++;
                }

                Console.WriteLine(res);
                //Console.WriteLine(string.Format(NumberFormatInfo.InvariantInfo, "{0:F4}", res));
#if !ONLINE_JUDGE
                Console.ReadLine();
            }
            Console.In.Close();
            Console.Out.Close();
#endif
        }

        private static char[] _defaultSplitter = new char[] { ' ', '\t' };

        private static char[] ReadChars(int n)
        {
            char[] buffer = new char[n];
            Console.In.ReadBlock(buffer, 0, n);
            return buffer;
        }

        private static string[] ReadAll()
        {
            return Console.In.ReadToEnd().Split(new char[] { ' ', '\t', '\n', '\r' }, StringSplitOptions.RemoveEmptyEntries);
        }

        private static string[] ReadWords(char[] splitter)
        {
            return Console.ReadLine().Split(splitter, StringSplitOptions.RemoveEmptyEntries);
        }

        private static string[] ReadWords()
        {
            return ReadWords(_defaultSplitter);
        }

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

        private static int[] ReadInts(char[] splitter)
        {
            return Console.ReadLine().Split(splitter, StringSplitOptions.RemoveEmptyEntries).Select(x => int.Parse(x)).ToArray();
        }

        private static int[] ReadInts()
        {
            return ReadInts(_defaultSplitter);
        }

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

        private static long[] ReadLongs(char[] splitter)
        {
            return Console.ReadLine().Split(splitter, StringSplitOptions.RemoveEmptyEntries).Select(x => long.Parse(x)).ToArray();
        }

        private static long[] ReadLongs()
        {
            return ReadLongs(_defaultSplitter);
        }

        private static double ReadDouble()
        {
            return double.Parse(Console.ReadLine(), NumberFormatInfo.InvariantInfo);
        }

        private static int _pos = 0;
        private static string[] _inputLine = new string[0];

        private static void CheckInputLine()
        {
            if (_pos >= _inputLine.Length)
            {
                _inputLine = ReadWords();
                _pos = 0;
            }
        }

        private static string NextWord()
        {
            CheckInputLine();
            return _inputLine[_pos++];
        }

        private static int NextInt()
        {
            CheckInputLine();
            return int.Parse(_inputLine[_pos++]);
        }

        private static long NextLong()
        {
            CheckInputLine();
            return long.Parse(_inputLine[_pos++]);
        }
    }
}


using System;

namespace CSharp
{
    class _538A
    {
        public static void Main()
        {
            string codeforces = "CODEFORCES";
            string banner = Console.ReadLine();

            for (int i = 0; i <= codeforces.Length; i++)
            {
                if (banner.Length >= codeforces.Length && banner.StartsWith(codeforces.Substring(0, i)) && banner.EndsWith(codeforces.Substring(i, codeforces.Length - i)))
                {
                    Console.WriteLine("YES");
                    return;
                }
            }

            Console.WriteLine("NO");
        }
    }
}


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

namespace Codeforces
{
   class A
   {
     static void Main(string[] args)
     {
       int n = int.Parse(Console.ReadLine());

       List<int> a = new List<int>();
       string[] token = Console.ReadLine().Split();

       for(int i=0;i<n;i++){
         if(int.Parse(token[i])!=0)
           a.Add(int.Parse(token[i]));
       }

       a.Sort();

       int val = a[0];

       int ans = 1;

       for(int i=0;i<a.Count;i++){
         if(a[i]!=val){
           val = a[i];
           ans++;
         }
       }

       Console.WriteLine(ans);

     }
   }
}


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

namespace Mex
{
    class Program
    {
        static void Main(string[] args)
        {
            long n, s;
            string input = Console.ReadLine();
            n = Convert.ToInt64(input.Split(' ')[0]);
            s = Convert.ToInt64(input.Split(' ')[1]);

            for(long i = s + 1; i <= n; i++)
            {
                if(i - SumOfDigits(i) >= s)
                {
                    Console.WriteLine(n - i + 1);
                    return;
                }
            }

            Console.WriteLine(0);
        }

        public static int SumOfDigits(long n)
        {
            string digits = n.ToString();
            int sum = 0;

            for(int i = 0; i < digits.Length; i++)
            {
                sum += Convert.ToInt32(digits[i].ToString());
            }

            return sum;
        }
    }
}


using System;

namespace test
{
    class Program
    {
        static void Main()
        {
            string txt;
            const char zero = '0';
            while ((txt = Console.ReadLine()) != null)
            {
                var max = int.Parse(txt.Split(' ')[1]);
                var step = 1;
                var d = Console.ReadLine();

                if (max == 1)
                {
                    step = d.Contains("0") ? -1 : d.Length - 1;
                }
                else
                {
                    var i = max;
                    var last = d.Length - 1;
                    while (i < last)
                    {
                        var j = max;
                        while (j > 1)
                        {
                            if (d[i] != zero)
                            {
                                i += max;
                                step++;
                                break;
                            }
                            i--;
                            j--;
                        }
                        if (j == 1)
                        {
                            step = -1;
                            break;
                        }
                    }
                }

                Console.WriteLine(step);
            }
        }
    }
}


using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;

class Program
{
    public static int[] Read(string str)
    {
        string[] tokens = str.Trim().Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries);
        int[] ret = new int[tokens.Length];
        for (int i = 0; i < ret.Length; i++)
        {
            ret[i] = int.Parse(tokens[i]);
        }

        return ret;
    }

    public static double[] ReadDouble(string str)
    {
        string[] tokens = str.Trim().Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries);
        double[] ret = new double[tokens.Length];
        for (int i = 0; i < ret.Length; i++)
        {
            ret[i] = double.Parse(tokens[i], CultureInfo.InvariantCulture);
        }

        return ret;
    }

    static string Reverse(string s)
    {
        char[] a = s.ToCharArray();
        Array.Reverse(a);
        return new string(a);
    }

    static void Main(string[] args)
    {
        long x = long.Parse(Console.ReadLine().Trim());
        if (x < 0) x = -x;

        if (x == 0)
        {
            Console.WriteLine(0);
            return;
        }

        int step = 1;
        long sum = 0;
        while (true)
        {
            sum += step;
            if (sum == x)
            {
                Console.WriteLine(step);
                break;
            }
            if (sum > x)
            {
                long t = sum - x;
                if (t % 2 == 0)
                {
                    Console.WriteLine(step);
                    break;
                }
            }
            step++;
        }
    }
}


using System;
class E
{
	static void Main()
	{
		var N = long.Parse(Console.ReadLine());
		if (N == 0) { Console.WriteLine("0 0"); return; }
		var k = FirstBinary(0, Math.Min(600000000, N), t => 3 * (t + 1) * (t + 2) >= N) + 1;
		var x = 2 * k;
		var y = 0L;
		var dx = new long[] { -1, -2, -1, 1, 2, 1 };
		var dy = new long[] { 2, 0, -2, -2, 0, 2 };
		N -= 3 * k * (k - 1) + 1;
		if (N < 0) N += 6 * k;
		for (var i = 0; i < 6; i++)
		{
			if (N < k)
			{
				N++;
				x += N * dx[i];
				y += N * dy[i];
				Console.WriteLine("{0} {1}", x, y);
				break;
			}
			N -= k;
			x += k * dx[i];
			y += k * dy[i];
		}
	}
	public static long FirstBinary(long min, long max, Predicate<long> pred)
	{
		var left = min;
		var right = max;
		while (left < right)
		{
			var mid = (left + right) >> 1;
			if (pred(mid)) right = mid;
			else left = mid + 1;
		}
		return left;
	}
}


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

namespace AlgorithmTrainning.Codeforce__round_200__set
{
    class probB
    {

        static int a, b, c;
        static void readInput()
        {
            String line = Console.ReadLine();
            String[] values = line.Split();
            a = int.Parse(values[0]);
            b = int.Parse(values[1]);
            c = int.Parse(values[2]);
        }

        static void solve()
        {
            int t = (a + b + c) /2;
            int z = t - a;
            int y = t - c;
            int x = t - b;
            if (x + y != a || y + z != b || z + x != c || z <0|| x<0 || y<0)
            {
                Console.WriteLine("Impossible");

            }
            else
            {
                Console.WriteLine(y + " " + z + " " + x);
            }

        }

        static void Main(String[] args)
        {
            readInput();
            solve();
        }

    }
}


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

namespace Zad_A
{
    class Program
    {
        static bool Polin(string s)
        {
            bool f = true;
            for (int i = 0; i < s.Length; i++)
            {
                if (s[i] != s[s.Length - i-1])
                {
                    f = false;
                }
            }
            return f;
        }

        static void Main(string[] args)
        {
            string s = Console.ReadLine();
            string c="";

            for (int i = 0; i < s.Length+1; i++)
            {
                for (int j = 0; j < 26; j++)
                {
                    c = s.Substring(0, i) + (char)(97 + j) + s.Substring(i, s.Length - i);
                    if (Polin(c)) break;
                }
                if (Polin(c)) break;
            }
            if (Polin(c))
                Console.WriteLine(c);
            else
                Console.WriteLine("NA");
        }

    }
}


using System;
using System.Linq;
using CompLib.Util;
using System.Threading;
using System.IO;

public class Program
{
    int N;
    int[] A;
    public void Solve()
    {
        var sc = new Scanner();
        N = sc.NextInt();
        A = sc.IntArray();

        // 配列a
        // 2つの部分列に分割
        // 2つの和が同じになるような分割が無い 良い

        int min = int.MaxValue;
        foreach (int i in A)
        {
            int tmp = 1;
            while ((i & tmp) == 0) tmp <<= 1;
            min = Math.Min(min, tmp);
        }
        for (int i = 0; i < N; i++)
        {
            A[i] /= min;
        }

        int sum = 0;
        bool[] dp = new bool[200001];
        dp[0] = true;
        foreach (int i in A)
        {
            for (int j = sum; j >= 0; j--)
            {
                if (dp[j]) dp[j + i] = true;
            }
            sum += i;
        }

        if (sum % 2 == 1 || !dp[sum / 2])
        {
            Console.WriteLine("0");
            return;
        }

        Console.WriteLine("1");
        for (int i = 0; i < N; i++)
        {
            if (A[i] % 2 == 1)
            {
                Console.WriteLine(i+1);
                return;
            }
        }
    }

    public static void Main(string[] args) => new Program().Solve();
    // public static void Main(string[] args) => new Thread(new Program().Solve, 1 << 27).Start();
}

namespace CompLib.Util
{
    using System;
    using System.Linq;

    class Scanner
    {
        private string[] _line;
        private int _index;
        private const char Separator = ' ';

        public Scanner()
        {
            _line = new string[0];
            _index = 0;
        }

        public string Next()
        {
            if (_index >= _line.Length)
            {
                string s;
                do
                {
                    s = Console.ReadLine();
                } while (s.Length == 0);

                _line = s.Split(Separator);
                _index = 0;
            }

            return _line[_index++];
        }

        public string ReadLine()
        {
            _index = _line.Length;
            return Console.ReadLine();
        }

        public int NextInt() => int.Parse(Next());
        public long NextLong() => long.Parse(Next());
        public double NextDouble() => double.Parse(Next());
        public decimal NextDecimal() => decimal.Parse(Next());
        public char NextChar() => Next()[0];
        public char[] NextCharArray() => Next().ToCharArray();

        public string[] Array()
        {
            string s = Console.ReadLine();
            _line = s.Length == 0 ? new string[0] : s.Split(Separator);
            _index = _line.Length;
            return _line;
        }

        public int[] IntArray() => Array().Select(int.Parse).ToArray();
        public long[] LongArray() => Array().Select(long.Parse).ToArray();
        public double[] DoubleArray() => Array().Select(double.Parse).ToArray();
        public decimal[] DecimalArray() => Array().Select(decimal.Parse).ToArray();
    }
}