using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Linq;
using System.Globalization;
using System.Threading;
using System.Web.Script.Serialization;

class Program
{
    private static void Main(string[] args)
    {
        long h1 = ReadInt();
        long h2 = ReadInt();
        long a = ReadInt();
        long b = ReadInt();

        h1 += 8 * a;

        if (a <= b && h1 < h2)
        {
            Console.Write(-1);
            return;
        }

        if (a <= b)
        {
            Console.Write(0);
            return;
        }

        long d1 = (h2 - h1);
        long d2 = (12 * (a - b));

        long days = Math.Max(0, (d1 + d2 - 1) / d2);

        Console.Write(days);
    }

    private static List<int>[] ReadGraph(int n, int m)
    {
        List<int>[] g = new List<int>[n + 1];
        for (int i = 0; i <= n; i++) g[i] = new List<int>();
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt() - 1;
            int b = ReadInt() - 1;

            g[a].Add(b);
            g[b].Add(a);
        }

        return g;
    }

    private static int[,] ReadGraphAsMatrix(int n, int m)
    {
        int[,] matrix = new int[n + 1, n + 1];
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt();
            int b = ReadInt();
            matrix[a, b] = matrix[b, a] = 1;
        }

        return matrix;
    }

    private static void Sort(ref int a, ref int b)
    {
        if (a > b) Swap(ref a, ref b);
    }

    private static void Swap(ref int a, ref int b)
    {
        int tmp = a;
        a = b;
        b = tmp;
    }

    private const int BufferSize = 1 << 16;
    private static StreamReader consoleReader;
    private static MemoryStream testData;

    private static int ReadInt()
    {
        int ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static ulong ReadULong()
    {
        ulong ans = 0;
        int chr;
        do
        {
            chr = consoleReader.Read();
            if (chr == -1)
                return 0;
        } while (chr < '0' || chr > '9');

        ans = (uint)(chr - '0');
        while (true)
        {
            chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans;
            ans = ans * 10 + (uint)(chr - '0');
        }
    }

    private static long ReadLong()
    {
        long ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static int[] ReadIntArray(int n)
    {
        int[] ans = new int[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadInt();
        return ans;
    }

    private static long[] ReadLongArray(int n)
    {
        long[] ans = new long[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadLong();
        return ans;
    }

    private static char[] ReadString()
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'a' || ans > 'z');

        List<char> s = new List<char>();
        do
        {
            s.Add((char)ans);
            ans = consoleReader.Read();
        } while (ans >= 'a' && ans <= 'z');

        return s.ToArray();
    }

    private static char[] ReadString(int n)
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'A' || ans > 'Z');

        char[] s = new char[n];
        int pos = 0;
        do
        {
            s[pos++] = (char)ans;
            if (pos == n) break;
            ans = consoleReader.Read();
        } while (ans >= 'A' && ans <= 'Z');

        return s;
    }

    private static char ReadLetter()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if ((ans >= 'a' && ans <= 'z') || (ans >= 'A' && ans <= 'Z'))
                return (char)ans;
        }
    }

    private static char ReadDigit()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if (ans >= '0' && ans <= '9')
                return (char)ans;
        }
    }

    private static int ReadDigitInt()
    {
        return ReadDigit() - (int)'0';
    }

    private static char ReadAnyChar()
    {
        return (char)consoleReader.Read();
    }

    private static string DoubleToString(double x)
    {
        return x.ToString(CultureInfo.InvariantCulture);
    }

    static Program()
    {
        //Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
        consoleReader = new StreamReader(Console.OpenStandardInput(BufferSize), Encoding.ASCII, false, BufferSize);
    }

    private static void PushTestData(string data)
    {
#if !ONLINE_JUDGE
        if (testData == null)
        {
            testData = new MemoryStream();
            consoleReader = new StreamReader(testData);
        }

        var pos = testData.Position;
        var bytes = Encoding.UTF8.GetBytes(data);
        testData.Write(bytes, 0, bytes.Length);
        testData.Flush();
        testData.Position = pos;
#endif
    }
}

using System;

namespace _652A
{
    class Program
    {
        static void Main()
        {
            var s1 = Console.ReadLine().Split();
            var h1 = int.Parse(s1[0]);
            var h2 = int.Parse(s1[1]);
            var h = h1;
            var s2 = Console.ReadLine().Split();
            var a = int.Parse(s2[0]);
            var b = int.Parse(s2[1]);
            var days = 0;
            while(true)
            {
                h += 8 * a;
                if (h >= h2) break;
                days++;
                h -= 12 * b;
                h += 4 * a;
                if (h <= h1) { days = -1; break; }

            }
            Console.WriteLine(days);
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed)
                {
                    if ((heightApple - heightCaterpillar) <= 8 * upSpeed)
                    {
                        daysPass = 0;
                        break;
                    }
                    else
                    {
                        daysPass = -1;
                        break;
                    }
                }
                else if (downSpeed == upSpeed)
                {
                    if ((heightApple - heightCaterpillar) <= 8 * upSpeed)
                    {
                        daysPass = 0;
                        break;
                    }
                    else
                    {
                        daysPass = -1;
                        break;
                    }
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int day = 0;
            int startPosition;
            int currentPosition;
            int applePosition;
            int upSpeed;
            int downSpeed;
            byte hour = 14;
            string input = Console.ReadLine();
            startPosition = int.Parse(input.Split(' ')[0]);
            applePosition = int.Parse(input.Split(' ')[1]);
            currentPosition = startPosition;
            input = Console.ReadLine();
            upSpeed = int.Parse(input.Split(' ')[0]);
            downSpeed = int.Parse(input.Split(' ')[1]);
            bool flag = upSpeed <= downSpeed;
            while (true)
            {
                if (hour >= 10 && hour < 22)
                {
                    currentPosition += upSpeed;
                }
                else
                {
                    currentPosition -= downSpeed;
                }
                if (currentPosition >= applePosition)
                {
                    break;
                }
                if (hour == 24)
                {
                    if (flag)
                    {
                        day = -1;
                        break;
                    }
                        hour = 0;
                        day++;

                }
                hour++;
            }
            Console.WriteLine(day.ToString());
          //  Console.ReadLine();
        }
    }
}

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

namespace CodeForces
{
	public class Program
	{
		public static void Main(string[] args)
		{
			//int n = int.Parse(Console.ReadLine());
			string num = Console.ReadLine();
			string[] numArr = num.Split(null);
			int h1 = int.Parse(numArr[0]);
			int h2 = int.Parse(numArr[1]);

			num = Console.ReadLine();
			numArr = num.Split(null);
			int a = int.Parse(numArr[0]);
			int b = int.Parse(numArr[1]);
			int diff = (a - b) * 12;
			h1 = h1 + (a * 8);
			int ans = 0;
			if (h1 >= h2)
			{
				ans = 0;
			}
			else if (a <= b)
			{
				ans = -1;
			}
			else
			{
				ans = (h2 - h1) / diff;
				ans += ((h2 - h1) % diff == 0) ? 0 : 1;
			}

			Console.WriteLine(ans);
		}
	}
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using System.Numerics;
using E = System.Linq.Enumerable;

namespace ProbA {
    class Program {
        protected IOHelper io;

        public Program(string inputFile, string outputFile) {
            io = new IOHelper(inputFile, outputFile, Encoding.Default);

            int h1 = io.NextInt(), h2 = io.NextInt();
            int a = io.NextInt(), b = io.NextInt();
            int days = 0, lastday = h1;
            while (h1 < h2) {
                h1 += 8 * a;
                if (h1 >= h2) break;
                h1 -= 12 * b;
                ++days;
                h1 += 4 * a;
                if (h1 >= h2) break;
                if (lastday >= h1) break;
            }
            if (lastday >= h1) io.WriteLine(-1);
            else io.WriteLine(days);
            io.Dispose();
        }

        static void Main(string[] args) {
            Program myProgram = new Program(null, null);
        }
    }

    class IOHelper : IDisposable {
        public StreamReader reader;
        public StreamWriter writer;

        public IOHelper(string inputFile, string outputFile, Encoding encoding) {
            if (inputFile == null)
                reader = new StreamReader(Console.OpenStandardInput(), encoding);
            else
                reader = new StreamReader(inputFile, encoding);

            if (outputFile == null)
                writer = new StreamWriter(Console.OpenStandardOutput(), encoding);
            else
                writer = new StreamWriter(outputFile, false, encoding);

            curLine = new string[] { };
            curTokenIdx = 0;
        }

        string[] curLine;
        int curTokenIdx;

        char[] whiteSpaces = new char[] { ' ', '\t', '\r', '\n' };

        public bool hasNext() {
            if (curTokenIdx >= curLine.Length) {
                //Read next line
                string line = reader.ReadLine();
                if (line != null)
                    curLine = line.Split(whiteSpaces, StringSplitOptions.RemoveEmptyEntries);
                else
                    curLine = new string[] { };
                curTokenIdx = 0;
            }

            return curTokenIdx < curLine.Length;
        }

        public string NextToken() {
            return hasNext() ? curLine[curTokenIdx++] : null;
        }

        public int NextInt() {
            return int.Parse(NextToken());
        }

        public double NextDouble() {
            string tkn = NextToken();
            return double.Parse(tkn, System.Globalization.CultureInfo.InvariantCulture);
        }

        public void Write(double val, int precision) {
            writer.Write(val.ToString("F" + precision, System.Globalization.CultureInfo.InvariantCulture));
        }

        public void Write(object stringToWrite) {
            writer.Write(stringToWrite);
        }

        public void WriteLine(double val, int precision) {
            writer.WriteLine(val.ToString("F" + precision, System.Globalization.CultureInfo.InvariantCulture));
        }

        public void WriteLine(object stringToWrite) {
            writer.WriteLine(stringToWrite);
        }

        public void Dispose() {
            try {
                if (reader != null) {
                    reader.Dispose();
                }
                if (writer != null) {
                    writer.Flush();
                    writer.Dispose();
                }
            } catch { };
        }

        public void Flush() {
            if (writer != null) {
                writer.Flush();
            }
        }
    }
}

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

namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
int day = 0;
int startPosition;
int currentPosition;
int applePosition;
int upSpeed;
int downSpeed;
byte hour = 14;
string input = Console.ReadLine();
startPosition = int.Parse(input.Split(' ')[0]);
applePosition = int.Parse(input.Split(' ')[1]);
currentPosition = startPosition;
input = Console.ReadLine();
upSpeed = int.Parse(input.Split(' ')[0]);
downSpeed = int.Parse(input.Split(' ')[1]);
bool flag = upSpeed <= downSpeed;
while (true)
{
if (hour >= 10 && hour < 22)
{
currentPosition += upSpeed;
}
else
{
currentPosition -= downSpeed;
}
if (currentPosition >= applePosition)
{
break;
}
if (hour == 24)
{
if (flag)
{
day = -1;
break;
}
hour = 0;
day++;
}
hour++;
}
Console.WriteLine(day.ToString());
}
}
}

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

namespace CodeForces
{
	public class Program
	{
		public static void Main(string[] args)
		{
			string[] h = Console.ReadLine().Split(null);
			int h1 = int.Parse(h[0]);
			int h2 = int.Parse(h[1]);

			h = Console.ReadLine().Split(null);
			int a = int.Parse(h[0]);
			int b = int.Parse(h[1]);

			h1 = h1 - 4 * a;

			int increase = 12 * a;
			int decrease = 12 * b;

			if(h2-h1 <= increase)
			{
				Console.Write("0");
			}
			else if (decrease >= increase)
			{
				Console.Write("-1");
			}
			else
			{
				int days = 0;
				while (true)
				{
					h1 = h1 + increase;
					if (h1 >= h2)
						break;

					h1 = h1 - decrease;
					days++;
				}

				Console.Write(days);
			}
		}
	}
}

using System;
using System.IO;
using System.Text;

namespace Gabriel_and_Caterpillar
{
    internal class Program
    {
        private static readonly StreamReader reader = new StreamReader(Console.OpenStandardInput(1024*10), Encoding.ASCII, false, 1024*10);
        private static readonly StreamWriter writer = new StreamWriter(Console.OpenStandardOutput(1024*10), Encoding.ASCII, 1024*10);

        private static void Main(string[] args)
        {
            int h1 = Next(), h2 = Next(), a = Next(), b = Next();

            int delta = h2 - 8*a - h1;
            if (delta <= 0)
                writer.WriteLine("0");
            else
            {
                if (a <= b)
                    writer.WriteLine("-1");
                else
                {
                    writer.WriteLine(1 + (delta-1)/(12*(a - b)));
                }
            }

            writer.Flush();
        }

        private static int Next()
        {
            int c;
            int res = 0;
            do
            {
                c = reader.Read();
                if (c == -1)
                    return res;
            } while (c < '0' || c > '9');
            res = c - '0';
            while (true)
            {
                c = reader.Read();
                if (c < '0' || c > '9')
                    return res;
                res *= 10;
                res += c - '0';
            }
        }
    }
}

#if DEBUG
using System.Reflection;
using System.Threading.Tasks;
#endif

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

namespace _10a
{
    class Program
    {
        static string _inputFilename = "input.txt";
        static string _outputFilename = "output.txt";
        static bool _useFileInput = false;

        static void Main(string[] args)
        {
            StreamWriter file = null;
#if DEBUG
			Console.SetIn(getInput());
#else
            if (_useFileInput)
            {
                Console.SetIn(File.OpenText(_inputFilename));
                file = new StreamWriter(_outputFilename);
                Console.SetOut(file);
            }
#endif

            try
            {
                solution();
            }
            finally
            {
                if (_useFileInput)
                {
                    file.Close();
                }
            }
        }

        static void solution()
        {
            #region SOLUTION
            var d = readIntArray();
            var h1 = d[0];
            var h2 = d[1];

            d = readIntArray();
            var a = d[0];
            var b = d[1];
            var up = (22 - 14 + 14 - 10) * a;
            var down = (10 + 2) * b;

            //var diff = h2 - h1;
            //if (diff <= 8 * a)
            //{
            //    Console.WriteLine(0);
            //    return;
            //}

            var dc = 0;
            var pos = h1 + 8 * a;
            while (true)
            {
                if (pos >= h2)
                {
                    Console.WriteLine(dc);
                    return;
                }

                if (12 * a <= 12 * b)
                {
                    Console.WriteLine(-1);
                    return;
                }

                pos -= 12 * b;
                pos += 12 * a;
                dc++;
            }

            //if (down >= up)
            //{
            //    Console.WriteLine(-1);
            //    return;
            //}

            //var di = up - down;
            //var count = diff / di;
            //var rem = diff % di;
            //if (rem <= 8 * a)
            //{
            //    Console.WriteLine(count);
            //    return;
            //}
            //else
            //{
            //    Console.WriteLine(count + 1);
            //    return;
            //}

            //var n = readInt();
            //var m = readInt();

            //var a = readIntArray();
            //var b = readIntArray();
            #endregion
        }

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

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

        static int[] readIntArray()
        {
            return Console.ReadLine().Split(' ').Where(i => !string.IsNullOrEmpty(i)).Select(i => int.Parse(i)).ToArray();
        }

        static long[] readLongArray()
        {
            return Console.ReadLine().Split(' ').Where(i => !string.IsNullOrEmpty(i)).Select(i => long.Parse(i)).ToArray();
        }

#if DEBUG
		static StreamReader getInput()
		{
			var resName = Assembly.GetCallingAssembly().GetManifestResourceNames()[0];
			var resource = Assembly.GetCallingAssembly().GetManifestResourceStream(resName);

			return new StreamReader(resource);
		}
#endif
    }
}

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

class PS
{

    static void Main(String[] args) {
        Console.WriteLine(solve());
    }

    static int solve() {
        var tmp = Console.ReadLine().Split(' ');
        int h1 = int.Parse(tmp[0]);
        int h2 = int.Parse(tmp[1]);

        tmp = Console.ReadLine().Split(' ');
        int a = int.Parse(tmp[0]);
        int b = int.Parse(tmp[1]);

        h1 += 8 * a;
        if (h1 >= h2) return 0;
        if (b >= a) return -1;
        h1 -= 12 * b;

        int d = 1;
        while (h1 < h2) {
            h1 += 12 * a;
            if (h1 >= h2) return d;
            d++;
            h1 -= 12 * b;
        }
        return d;
    }
}

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

namespace CF317
{
	internal class Program
	{
		private static void Main(string[] args)
		{
			var sr = new InputReader(Console.In);
			//var sr = new InputReader(new StreamReader("input.txt"));
			var task = new Task();
			using (var sw = Console.Out) {
				task.Solve(1, sr, sw);
				//Console.ReadKey();
			}
		}
	}

	internal class Task
	{
		public void Solve(int testNumber, InputReader sr, TextWriter sw)
		{
			var input = sr.ReadArray(Int64.Parse);
			var h1 = input[0];
			var h2 = input[1];
			input = sr.ReadArray(Int64.Parse);
			var a = input[0];
			var b = input[1];
			const int count = 8;
			if (a * count + h1 >= h2) {
				sw.WriteLine(0);
				return;
			}
			if (a <= b) {
				sw.WriteLine(-1);
			}
			h1 += a * count;
			var day = 1;
			for (var i = 0; i < 100001; i++,day++) {
				h1 -= b * 12;
				h1 += a * 12;
				if (h1 >= h2) {
					sw.WriteLine(day);
					return;
				}
			}
		}
	}

	internal class InputReader : IDisposable
	{
		private bool isDispose;
		private readonly TextReader sr;

		public InputReader(TextReader stream)
		{
			sr = stream;
		}

		public void Dispose()
		{
			Dispose(true);
			GC.SuppressFinalize(this);
		}

		public string NextString()
		{
			var result = sr.ReadLine();
			return result;
		}

		public int NextInt32()
		{
			return Int32.Parse(NextString());
		}

		public long NextInt64()
		{
			return Int64.Parse(NextString());
		}

		public string[] NextSplitStrings()
		{
			return NextString()
				.Split(new[] { ' ' }, StringSplitOptions.RemoveEmptyEntries);
		}

		public T[] ReadArray<T>(Func<string, CultureInfo, T> func)
		{
			return NextSplitStrings()
				.Select(s => func(s, CultureInfo.InvariantCulture))
				.ToArray();
		}

		public T[] ReadArrayFromString<T>(Func<string, CultureInfo, T> func, string str)
		{
			return
				str.Split(new[] { ' ' }, StringSplitOptions.RemoveEmptyEntries)
					.Select(s => func(s, CultureInfo.InvariantCulture))
					.ToArray();
		}

		protected void Dispose(bool dispose)
		{
			if (!isDispose) {
				if (dispose)
					sr.Close();
				isDispose = true;
			}
		}

		~InputReader()
		{
			Dispose(false);
		}
	}
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void SetTwo(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Main()
        {
            long h1;
            long h2;
            SetTwo(out h1, out h2);

            long a;
            long b;
            SetTwo(out a, out b);

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            Print(BinarySearchGe(1, 100000, h2, f));
        }

        private static long BinarySearchGe(long low, long high, long goal, Func<long, long> f)
        {
            if (f(high) < goal)
            {
                return -1;
            }

            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            return low;
        }

        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 >= h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u <= d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d *= 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            float num = (float)Math.Ceiling(hDif / dif);
            Console.WriteLine(num);
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Main()
        {
            long h1;
            long h2;
            ReadLine(out h1, out h2);

            long a;
            long b;
            ReadLine(out a, out b);

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            Print(BinarySearchGe(1, 100000, h2, f));
        }

        private static long BinarySearchGe(long low, long high, long goal, Func<long, long> f)
        {
            if (f(high) < goal)
            {
                return -1;
            }

            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            return low;
        }

        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            var result = BinarySearch(1, 100000, h2, f);

            Print(result);

            //for (var i = 1; ; i++)
            //{
            //    if (h2 <= h1 + a8 + (a12 - b12) * i)
            //    {
            //        Print(i);
            //        return;
            //    }
            //}
        }

        private static long BinarySearch(long low, long high, long goal, Func<long, long> f)
        {
            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            if (goal < f(low)) return low;
            if (goal < f(high)) return high;
            return -1;
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            Print(BinarySearchGe(1, 100000, h2, f));
        }

        private static long BinarySearchGe(long low, long high, long goal, Func<long, long> f)
        {
            if (f(high) < goal)
            {
                return -1;
            }

            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            return low;
        }

        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            Print(BinarySearchGe(1, 100000, h2, f));
        }

        private static long BinarySearchGe(long low, long high, long goal, Func<long, long> f)
        {
            if (f(high) < goal)
            {
                return -1;
            }

            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            return low;
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
    }
}

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

namespace Gabriel
{
    class Program
    {
        static void Main(string[] args)
        {

            string tmp = Console.ReadLine();
            string[] tmp1 = tmp.Split(' ');
            int[] heights = Array.ConvertAll(tmp1, int.Parse);
            string grow = Console.ReadLine();
            string[] shrink = grow.Split(' ');
            int[] gs = Array.ConvertAll(shrink, int.Parse);
            int h1 = heights[0];
            int h2 = heights[1];

            int h = h1;

            int days = 0;
            int a = gs[0];
            int b = gs[1];
            while (true)
            {
                h += 8 * a;
                if (h >= h2) break;
                days++;
                h -= 12 * b;
                h += 4 * a;
                if (h <= h1) { days = -1; break; }

            }
            Console.WriteLine(days);

        }
    }
}

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

// (づ°ω°)づﾐe★゜・。。・゜゜・。。・゜☆゜・。。・゜゜・。。・゜
public class Solver
{
    public void Solve()
    {
        int h1 = ReadInt();
        int h2 = ReadInt();
        int a = ReadInt();
        int b = ReadInt();

        h1 += a * 8;
        if (h1 >= h2)
        {
            Write(0);
            return;
        }

        if (b >= a)
        {
            Write(-1);
            return;
        }

        Write((h2 - h1 - 1) / (12 * (a - b)) + 1);
    }

    #region Main

    protected static TextReader reader;
    protected static TextWriter writer;
    static void Main()
    {
#if DEBUG
        reader = new StreamReader("..\\..\\input.txt");
        //reader = new StreamReader(Console.OpenStandardInput());
        writer = Console.Out;
        //writer = new StreamWriter("..\\..\\output.txt");
#else
        reader = new StreamReader(Console.OpenStandardInput());
        writer = new StreamWriter(Console.OpenStandardOutput());
        //reader = new StreamReader("input.txt");
        //writer = new StreamWriter("output.txt");
#endif
        try
        {
            //var thread = new Thread(new Solver().Solve, 1024 * 1024 * 128);
            //thread.Start();
            //thread.Join();
            new Solver().Solve();
        }
        catch (Exception ex)
        {
            Console.WriteLine(ex);
#if DEBUG
#else
            throw;
#endif
        }
        reader.Close();
        writer.Close();
    }

    #endregion

    #region Read / Write
    private static Queue<string> currentLineTokens = new Queue<string>();
    private static string[] ReadAndSplitLine() { return reader.ReadLine().Split(new[] { ' ', '\t', }, StringSplitOptions.RemoveEmptyEntries); }
    public static string ReadToken() { while (currentLineTokens.Count == 0)currentLineTokens = new Queue<string>(ReadAndSplitLine()); return currentLineTokens.Dequeue(); }
    public static int ReadInt() { return int.Parse(ReadToken()); }
    public static long ReadLong() { return long.Parse(ReadToken()); }
    public static double ReadDouble() { return double.Parse(ReadToken(), CultureInfo.InvariantCulture); }
    public static int[] ReadIntArray() { return ReadAndSplitLine().Select(int.Parse).ToArray(); }
    public static long[] ReadLongArray() { return ReadAndSplitLine().Select(long.Parse).ToArray(); }
    public static double[] ReadDoubleArray() { return ReadAndSplitLine().Select(s => double.Parse(s, CultureInfo.InvariantCulture)).ToArray(); }
    public static int[][] ReadIntMatrix(int numberOfRows) { int[][] matrix = new int[numberOfRows][]; for (int i = 0; i < numberOfRows; i++)matrix[i] = ReadIntArray(); return matrix; }
    public static int[][] ReadAndTransposeIntMatrix(int numberOfRows)
    {
        int[][] matrix = ReadIntMatrix(numberOfRows); int[][] ret = new int[matrix[0].Length][];
        for (int i = 0; i < ret.Length; i++) { ret[i] = new int[numberOfRows]; for (int j = 0; j < numberOfRows; j++)ret[i][j] = matrix[j][i]; } return ret;
    }
    public static string[] ReadLines(int quantity) { string[] lines = new string[quantity]; for (int i = 0; i < quantity; i++)lines[i] = reader.ReadLine().Trim(); return lines; }
    public static void WriteArray<T>(IEnumerable<T> array) { writer.WriteLine(string.Join(" ", array)); }
    public static void Write(params object[] array) { WriteArray(array); }
    public static void WriteLines<T>(IEnumerable<T> array) { foreach (var a in array)writer.WriteLine(a); }
    private class SDictionary<TKey, TValue> : Dictionary<TKey, TValue>
    {
        public new TValue this[TKey key]
        {
            get { return ContainsKey(key) ? base[key] : default(TValue); }
            set { base[key] = value; }
        }
    }
    private static T[] Init<T>(int size) where T : new() { var ret = new T[size]; for (int i = 0; i < size; i++)ret[i] = new T(); return ret; }
    #endregion
}

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

public static class P
{
    public static void Main()
    {
        var h = Console.ReadLine().Split().Select(long.Parse).ToArray();
        var h1 = h[0];
        var h2 = h[1];
        var ab = Console.ReadLine().Split().Select(long.Parse).ToArray();
        h1 += ab[0] * 8;
        if (h2 <= h1)
        {
            Console.WriteLine(0);
            return;
        }
        if (ab[0] <= ab[1])
        {
            Console.WriteLine(-1);
            return;
        }
        int day = 1;
        while (true)
        {
            h1 -= ab[1] * 12;
            h1 += ab[0] * 12;
            if (h2 <= h1)
            {
                Console.WriteLine(day);
                return;
            }
            day++;
        }
    }
}

using System;

class Capellitar
{
	static void Main()
	{
		string[] tmp = Console.ReadLine().Split();
		uint h1 = uint.Parse( tmp[0] );
		uint h2 = uint.Parse( tmp[1] );
		tmp = Console.ReadLine().Split();
		uint a = uint.Parse( tmp[0] );
		uint b = uint.Parse( tmp[1] );
		if( b >= a && (h1+a*8) < h2 )
			Console.WriteLine( -1 );
		else {
			uint days = 0;
			h1 += 8*a;
			while( !(h1 >= h2) )
			{
				h1 -= 12*b;
				h1 += 12*a;
				days++;
			}
			Console.WriteLine( days );
		}
	}
}

using System;

namespace _A
{
	class MainClass
	{
		public static void Main (string[] args)
		{

			string[] Temp;
			int h1, h2, a, b;

			Temp = Console.ReadLine ().Split (' ');
			h1 = int.Parse (Temp [0]);
			h2 = int.Parse (Temp [1]);
			Temp = Console.ReadLine ().Split (' ');
			a = int.Parse (Temp [0]);
			b = int.Parse (Temp [1]);

			bool itCant = false;
			int lasth1 = h1;

			int Days = 0;
			h1 -= a * 4;

			while (h1 < h2) {
				//8

				h1 += a * 12;
				if (h1 >= h2)
					break;

				//12
				h1 -= b * 8;
				if (lasth1 >= h1) {

					itCant = true;
					break;

				}

				h1 -= b * 4;

				Days++;
			}

			if (itCant)
				Console.WriteLine ("-1");
			else
				Console.WriteLine (Days);

			Console.ReadLine ();

		}
	}
}

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

class Solver
{
    public void Solve(Scanner sc)
    {
        int h1, h2,a,b;
        sc.Make(out h1, out h2, out a, out b);
        var d = h2 - h1;
        if (d <= a * 8) Fail(0);
        if (a <= b) Fail(-1);
        WriteLine((d - a * 8+(a-b)*12-1) / ((a - b) * 12));
    }
}

#region Template
public static class Template
{
    static void Main(string[] args)
    {
        Console.SetOut(new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false });
        new Solver().Solve(new Scanner());
        Console.Out.Flush();
    }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmin<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == 1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static bool chmax<T>(ref T a, T b) where T : IComparable<T> { if (a.CompareTo(b) == -1) { a = b; return true; } return false; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static void swap<T>(ref T a, ref T b) { var t = b; b = a; a = t; }
    public static T[] Shuffle<T>(this IList<T> A) { T[] rt = A.ToArray(); Random rnd = new Random(); for (int i = rt.Length - 1; i >= 1; i--) swap(ref rt[i], ref rt[rnd.Next(i + 1)]); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(); return rt; }
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public static T[] Create<T>(int n, Func<int, T> f) { var rt = new T[n]; for (var i = 0; i < rt.Length; ++i) rt[i] = f(i); return rt; }
    public static void Fail<T>(T s) { Console.WriteLine(s); Console.Out.Close(); Environment.Exit(0); }
}
public class Scanner
{
    public string Str => Console.ReadLine().Trim();
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public int[] ArrInt => Str.Split(' ').Select(int.Parse).ToArray();
    public long[] ArrLong => Str.Split(' ').Select(long.Parse).ToArray();
    public char[][] Grid(int n) => Create(n, () => Str.ToCharArray());
    public int[] ArrInt1D(int n) => Create(n, () => Int);
    public long[] ArrLong1D(int n) => Create(n, () => Long);
    public int[][] ArrInt2D(int n) => Create(n, () => ArrInt);
    public long[][] ArrLong2D(int n) => Create(n, () => ArrLong);
    private Queue<string> q = new Queue<string>();
    [MethodImpl(MethodImplOptions.AggressiveInlining)]
    public T Next<T>() { if (q.Count == 0) foreach (var item in Str.Split(' ')) q.Enqueue(item); return (T)Convert.ChangeType(q.Dequeue(), typeof(T)); }
    public void Make<T1>(out T1 v1) => v1 = Next<T1>();
    public void Make<T1, T2>(out T1 v1, out T2 v2) { v1 = Next<T1>(); v2 = Next<T2>(); }
    public void Make<T1, T2, T3>(out T1 v1, out T2 v2, out T3 v3) { Make(out v1, out v2); v3 = Next<T3>(); }
    public void Make<T1, T2, T3, T4>(out T1 v1, out T2 v2, out T3 v3, out T4 v4) { Make(out v1, out v2, out v3); v4 = Next<T4>(); }
    public void Make<T1, T2, T3, T4, T5>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5) { Make(out v1, out v2, out v3, out v4); v5 = Next<T5>(); }
    public void Make<T1, T2, T3, T4, T5, T6>(out T1 v1, out T2 v2, out T3 v3, out T4 v4, out T5 v5, out T6 v6) { Make(out v1, out v2, out v3, out v4, out v5); v6 = Next<T6>(); }
    //public (T1, T2) Make<T1, T2>() { Make(out T1 v1, out T2 v2); return (v1, v2); }
    //public (T1, T2, T3) Make<T1, T2, T3>() { Make(out T1 v1, out T2 v2, out T3 v3); return (v1, v2, v3); }
    //public (T1, T2, T3, T4) Make<T1, T2, T3, T4>() { Make(out T1 v1, out T2 v2, out T3 v3, out T4 v4); return (v1, v2, v3, v4); }
}
public class Pair<T1, T2> : IComparable<Pair<T1, T2>>
{
    public T1 v1;
    public T2 v2;
    public Pair() { }
    public Pair(T1 v1, T2 v2)
    { this.v1 = v1; this.v2 = v2; }

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

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

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

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed >= upSpeed)
                {
                    if ((heightApple - heightCaterpillar) <= 8 * upSpeed)
                    {
                        daysPass = 0;
                        break;
                    }
                    else
                    {
                        daysPass = -1;
                        break;
                    }
                }
                //else if (downSpeed == upSpeed)
                //{
                //    if ((heightApple - heightCaterpillar) <= 8 * upSpeed)
                //    {
                //        daysPass = 0;
                //        break;
                //    }
                //    else
                //    {
                //        daysPass = -1;
                //        break;
                //    }
                //}

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Codeforces1
{
    class Program
    {
        static void Main(string[] args)
        {
            Program pr = new Program();
            pr.test();
        }
        void test()
        {

            string Stroka_1 = Console.ReadLine();

            string Stroka_2 = Console.ReadLine();
            int H1, H2, h1, i = 0, our = 14, a = 0, b = 0, day = 0;
            string[] str1 = Stroka_1.Split(' ');
            string[] str2 = Stroka_2.Split(' ');
            H1 = int.Parse(str1[i]);
            i++;
            H2 = int.Parse(str1[i]);
            i = 0;
            a = int.Parse(str2[i]);
            i++;
            b = int.Parse(str2[i]);

            h1 = H1;
            while (true)
            {
                while (our != 22)
                {
                    h1 += a;
                    if (h1 >= H2)
                    {
                        Console.Write(day);

                        return;
                    }
                    else our++;
                }
                day++;
                while (our != 10)
                {
                    h1 -= b;
                    our--;
                }
                if ((h1 + 4 * a) <= H1)
                {
                    Console.Write("-1");

                    return;
                }
            }
        }
    }
}

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

public static class P
{
    public static void Main()
    {
        var h = Console.ReadLine().Split().Select(long.Parse).ToArray();
        var h1 = h[0];
        var h2 = h[1];
        var ab = Console.ReadLine().Split().Select(long.Parse).ToArray();
        h1 += ab[0] * 8;
        if (h2 <= h1)
        {
            Console.WriteLine(0);
            return;
        }
        if (ab[0] <= ab[1])
        {
            Console.WriteLine(-1);
            return;
        }
        int day = 1;
        while (true)
        {
            h1 -= ab[1] * 10;
            h1 += ab[0] * 10;
            if (h2 <= h1)
            {
                Console.WriteLine(day);
                return;
            }
            day++;
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {

                if ((upSpeed == 1) && (heightApple - heightCaterpillar) > 8 || (heightApple - heightCaterpillar) < downSpeed)
                {
                    daysPass = -1;
                    break;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 3;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
                Console.WriteLine("Looping");

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime <= 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                // Console.WriteLine("Looping" + wormPos);
                if ((((downSpeed > upSpeed) || upSpeed == 1 && downSpeed == 1) && (heightApple - heightCaterpillar) > 8))
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {

                if (upSpeed == 1 && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }
                if (downSpeed > upSpeed)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                }
                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed)
                {
                    daysPass = -1;
                    break;
                }
                else if (downSpeed == upSpeed)
                {
                    if ((heightApple - heightCaterpillar) <= 8)
                    {
                        daysPass = 0;
                        break;
                    }
                    else
                    {
                        daysPass = -1;
                        break;
                    }
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {

                if (upSpeed == 1 && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (downSpeed > upSpeed && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {

                if ((upSpeed == 1) && (heightApple - heightCaterpillar) > 8 || downSpeed > heightApple || downSpeed > (heightApple - heightCaterpillar))
                {
                    daysPass = -1;
                    break;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();

            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
           // p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed)
                {
                    daysPass = -1;
                    Console.WriteLine(daysPass + " Breaked");
                    break;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
                //   Console.WriteLine("Looping");

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                //  Console.WriteLine("Looping" + wormPos);
                if ((downSpeed > upSpeed || (heightApple - heightCaterpillar) > 8))
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {

                if ((upSpeed == 1) && (heightApple - heightCaterpillar) > 8 || (heightApple - heightCaterpillar) > downSpeed)
                {
                    daysPass = -1;
                    break;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed)
                {
                    if ((heightApple - heightCaterpillar) <= 8)
                    {
                        daysPass = 0;
                        break;
                    }
                    else
                    {
                        daysPass = -1;
                        break;
                    }
                }
                else if (downSpeed == upSpeed)
                {
                    if ((heightApple - heightCaterpillar) <= 8)
                    {
                        daysPass = 0;
                        break;
                    }
                    else
                    {
                        daysPass = -1;
                        break;
                    }
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {

                if (upSpeed == 1 && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {

                if ((upSpeed == 1) && (heightApple - heightCaterpillar) > 8 || downSpeed > heightApple)
                {
                    daysPass = -1;
                    break;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec <= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
                //Console.WriteLine("Looping");

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime <= 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
                Console.WriteLine(wormPos + " pos");

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();
            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
            //   p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 3;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed && (heightApple - heightCaterpillar) > 8)
                {
                    daysPass = -1;
                    //Console.WriteLine(daysPass + " Breaked");
                    break;
                    // return;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
               // Console.WriteLine("Looping");

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace Gabriel_and_Worm
{
    class Program
    {
        static void Main(string[] args)
        {
            Program p = new Program();

            string[] tokens = Console.ReadLine().Split();
            string[] tokens2 = Console.ReadLine().Split();

            int htCtr = int.Parse(tokens[0]);

            //Parse element 1
            int htApple = int.Parse(tokens[1]);

            int up = int.Parse(tokens2[0]);

            //Parse element 1
            int down = int.Parse(tokens2[1]);

            p.Ankush(htCtr, htApple, up, down);
           // p.Ankush(12, 120, 5, 3);
        }

        public void Ankush(int heightCaterpillar, int heightApple, int upSpeed, int downSpeed)
        {
            int wormPos = heightCaterpillar;

            int daytime = 4;
            int nightDec = 0;
            int daysPass = 0;

            while (wormPos < heightApple)
            {
                if (downSpeed > upSpeed)
                {
                    daysPass = -1;
                 //   Console.WriteLine(daysPass + " Breaked");
                    break;
                }

                if (daytime < 12)
                {
                    wormPos += upSpeed;
                    daytime++;
                }
                else
                {
                    nightDec++;
                    wormPos -= downSpeed;
                    if (nightDec >= 12)
                    {
                        nightDec = 0;
                        daytime = 0;
                        daysPass++;
                    }
                }
                //   Console.WriteLine("Looping");

            }

            Console.WriteLine(daysPass);
            Console.Read();
        }
    }
}

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

namespace CodeForces
{
	public class Program
	{
		public static void Main(string[] args)
		{
			//int n = int.Parse(Console.ReadLine());
			string num = Console.ReadLine();
			string[] numArr = num.Split(null);
			int h1 = int.Parse(numArr[0]);
			int h2 = int.Parse(numArr[1]);

			num = Console.ReadLine();
			numArr = num.Split(null);
			int a = int.Parse(numArr[0]);
			int b = int.Parse(numArr[1]);
			int diff = (a - b) * 12;
			h1 = h1 + (a * 8);
			int ans = 0;
			if (h1 > h2)
			{
				ans = 0;
			}
			else if (a <= b)
			{
				ans = -1;
			}
			else
			{
				ans = (h2 - h1) / diff;
				ans += ((h2 - h1) % diff == 0) ? 0 : 1;
			}

			Console.WriteLine(ans);
		}
	}
}

using System;
using System.IO;
using System.Text;

namespace Gabriel_and_Caterpillar
{
    internal class Program
    {
        private static readonly StreamReader reader = new StreamReader(Console.OpenStandardInput(1024*10), Encoding.ASCII, false, 1024*10);
        private static readonly StreamWriter writer = new StreamWriter(Console.OpenStandardOutput(1024*10), Encoding.ASCII, 1024*10);

        private static void Main(string[] args)
        {
            int h1 = Next(), h2 = Next(), a = Next(), b = Next();

            int delta = h2 - 8*a - h1;
            if (delta <= 0)
                writer.WriteLine("0");
            else
            {
                if (a <= b)
                    writer.WriteLine("-1");
                else
                {
                    writer.WriteLine(1 + delta/(12*(a - b)));
                }
            }

            writer.Flush();
        }

        private static int Next()
        {
            int c;
            int res = 0;
            do
            {
                c = reader.Read();
                if (c == -1)
                    return res;
            } while (c < '0' || c > '9');
            res = c - '0';
            while (true)
            {
                c = reader.Read();
                if (c < '0' || c > '9')
                    return res;
                res *= 10;
                res += c - '0';
            }
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            var result = BinarySearch(1, 100000, h2, f);

            Print(result);

            //for (var i = 1; ; i++)
            //{
            //    if (h2 <= h1 + a8 + (a12 - b12) * i)
            //    {
            //        Print(i);
            //        return;
            //    }
            //}
        }

        private static long BinarySearch(long low, long high, long goal, Func<long, long> f)
        {
            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            return low;
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            //ReadLine(out h1, out h2);

            long a, b;
            //ReadLine(out a, out b);

            h1 = 0;
            h2 = 28;
            a = 2;
            b = 1;

            h1 += 8 * a;

            if (h2 <= h1)
            {
                Print(0);
                return;
            }

            if (a <= b)
            {
                Print(-1);
                return;
            }

            var d = 12 * (a - b);

            Print((h2 - h1) / d);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            h1 = h1 + 8 * a;

            if (h2 <= h1)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            h1 += -12 * b;

            for (long i = 1; ; i++)
            {
                h1 += 12 * (a - b);
                if (h2 <= h1 + 12 * a)
                {
                    if (h2 <= h1 + 12 - b)
                        Print(i );
                    else
                        Print(i-1);
                    return;
                }
            }
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            var d = 12 * (a - b);

            h1 += 8 * a;
            Print((h2 - h1)  / d + 1);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            h1 = h1 + 8 * a;

            if (h2 <= h1)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            h1 += -12 * b;

            for (long i = 1; ; i++)
            {
                h1 += 12 * (a - b);
                if (h2 <= h1 + 12 * a)
                {
                    Print(i);
                    return;
                }
            }
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            h1 -= 4 * a;

            if (a <= b && 12 * a + h1 < h2)
            {
                Print(-1);
                return;
            }

            if (a <= b)
            {
                Print(0);
                return;
            }

            var d1 = h2 - h1 - 12 * a;
            var d2 = 12 * (a - b);

            Print((d1 + d2 - 1) / d2);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            var d = 12 * (a - b);

            h1 += 8 * a;
            Print((h2 - h1) / d);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            var h = (22 - 14) * a + h1;

            var firsth = h;

            if (h2 <= h)
            {
                Print(0);
                return;
            }
            h = h - 12 * b;

            if (a < b)
            {
                Print(-1);
                return;
            }

            for (long i = 1; i < long.MaxValue; i++)
            {
                h = h + 12 * a;
                if (h2 <= h)
                {
                    Print(i);
                    return;
                }
                h = h - 12 * b;

                if (h <= firsth)
                {
                    Print(-1);
                    return;
                }
            }

            Console.ReadKey();
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            Print(BinarySearchGt(1, 100000, h2, f));
        }

        private static long BinarySearchGt(long low, long high, long goal, Func<long, long> f)
        {
            if (f(high) <= goal)
            {
                return -1;
            }

            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid + 1;
                }
            }

            return low;
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            h1 += 8 * a;

            if (h2 <= h1)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var b2 = 12 * b;

            h1 += -b2;

            var a2 = 12 * a;

            for (var i = 1; ; i += 2)
            {
                h1 += a2;
                if (h2 <= h1)
                {
                    h1 = h1 - a2 + b2;
                    if (h2 <= h1)
                    {
                        Print(i - 1);
                    }
                    else
                    {
                        Print(i);
                    }
                    return;
                }
                h1 -= b2;
            }
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            Func<long, long> f = i => h1 + a8 + (a12 - b12) * i;

            var result = BinarySearch(1, 100000, h2, f);

            Print(result);

            //for (var i = 1; ; i++)
            //{
            //    if (h2 <= h1 + a8 + (a12 - b12) * i)
            //    {
            //        Print(i);
            //        return;
            //    }
            //}
        }

        private static long BinarySearch(long low, long high, long goal, Func<long, long> f)
        {
            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            return goal < f(low) ? low : high;
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            var d = 12 * (a - b);

            Print((h2 - (h1 + 8 * a + 1) + d) / d);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            var d = 12 * (a - b);

            Print((h2 - (h1 + 8 * a) + d) / d);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            h1 += 8 * a;

            if (h2 <= h1)
            {
                Print(0);
                return;
            }

            if (a <= b)
            {
                Print(-1);
                return;
            }

            var d = 12 * (a - b);

            Print((h2 - h1) / d + 1);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            //h1 = 10;
            //h2 = 13;
            //a = 1;
            //b = 1;

            h1 += 8 * a;

            if (h2 <= h1)
            {
                Print(0);
                return;
            }

            if (a <= b)
            {
                Print(-1);
                return;
            }

            var d = 12 * (a - b);

            Print((h2 - h1) / d);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            Print(1 + (h2 - (h1 + 8 * a + 1)) / (12 * (a - b)));
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            var d = 12 * (a - b);

            Print((h2 - h1 - 8 * a + d - 1) / d);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            var d = 12 * (a - b);

            Print((h2 - (h1 + 8 * a - 1) + d) / d);
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            var xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var h1 = xs[0];
            var h2 = xs[1];

            xs = Console.ReadLine().Split().Select(int.Parse).ToList();
            var a = xs[0];
            var b = xs[1];

            var a8 = 8 * a;

            if (h2 <= h1 + a8)
            {
                Print(0);
                return;
            }

            if (a < b)
            {
                Print(-1);
                return;
            }

            var a12 = 12 * a;
            var b12 = 12 * b;

            for (var i = 1; ; i++)
            {
                if (h2 <= h1 + a8 + (a12 + b12) * i)
                {
                    Print(i);
                    return;
                }
            }
        }

        private static long BinarySearch(long low, long high, long goal, Func<long, long> f)
        {
            while (low <= high)
            {
                var mid = (low + high) / 2;
                var x = f(mid);

                if (goal < x)
                {
                    high = mid - 1;
                }
                else if (x < goal)
                {
                    low = mid + 1;
                }
                else
                {
                    return mid;
                }
            }

            return -1;
        }

        private static void Print(string s) { Console.WriteLine(s); }
        private static void Print(long x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }
        private static void Print(double x) { Console.WriteLine(x.ToString(CultureInfo.InvariantCulture)); }

        private static string S(long x) { return x.ToString(CultureInfo.InvariantCulture); }
        private static string S(double x) { return x.ToString(CultureInfo.InvariantCulture); }
    }
}

using System;
using System.Globalization;
using System.Linq;

namespace Codeforces
{
    internal static class Program
    {
        private static void Main()
        {
            long h1, h2;
            ReadLine(out h1, out h2);

            long a, b;
            ReadLine(out a, out b);

            if (a <= b)
            {
                Print(8 * a + h1 < h2 ? -1 : 0);
                return;
            }

            Print(1 + (h2 - (h1 + 8 * a)) / 12 * (a - b));
        }

        private static void ReadLine(out long a, out long b)
        {
            var xs = Console.ReadLine().Split().Select(long.Parse).ToList();
            a = xs[0];
            b = xs[1];
        }

        private static void Print(long x)
        {
            Console.WriteLine(x.ToString(CultureInfo.InvariantCulture));
        }
    }
}

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

namespace Gabriel
{
    class Program
    {
        static void Main(string[] args)
        {

            string tmp = Console.ReadLine();
            string[] tmp1 = tmp.Split(' ');
            int[] heights = Array.ConvertAll(tmp1, int.Parse);
            string grow = Console.ReadLine();
            string[] shrink = grow.Split(' ');
            int[] gs = Array.ConvertAll(shrink, int.Parse);
            int h1 = heights[0];
            int h2 = heights[1];

            int h = h1;

            int days = 0;
            int a = gs[0];
            int b = gs[1];
            while (true)
            {
                h += 8 * a;
                if (h >= h2) break;
                days++;
                h -= 12 * b;
                h += 4 * a;
                if (h <= h1) days = -1; break;

            }
            Console.WriteLine(days);

        }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 > h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u < d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d *= 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            if(Math.Floor(hDif / dif) == float.PositiveInfinity)
            {
                Console.WriteLine(-1);
                return;
            }
            float num = hDif / dif;
            if (Math.Floor(num) == (num))
            {
                num--;
            }
            Console.WriteLine(Math.Floor(hDif / dif)+1);
            Console.Read();
        }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 > h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u < d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d *= 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            Console.WriteLine(Math.Floor(hDif / dif)+1);
        }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 > h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u < d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d *= 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            if(Math.Floor(hDif / dif) == float.PositiveInfinity)
            {
                Console.WriteLine(-1);
                return;
            }
            float num = hDif / dif;
            if (Math.Floor(num) == (num))
            {
                num--;
            }
            Console.WriteLine(Math.Floor(num)+1);
            Console.Read();
        }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 > h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u < d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d *= 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            if(Math.Floor(hDif / dif) == float.PositiveInfinity)
            {
                Console.WriteLine(-1);
                return;
            }
            Console.WriteLine(Math.Floor(hDif / dif)+1);
            Console.Read();
        }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 > h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u < d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d *= 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            if (Math.Floor(hDif / dif) == float.PositiveInfinity)
            {
                Console.WriteLine(-1);
                return;
            }
            float num = hDif / dif;
            if (Math.Floor(num) != (num))
            {
                num = (float)Math.Floor(num) + 1;
            }
            Console.WriteLine(num);
            Console.Read();
        }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 > h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u <= d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d *= 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            float num = (float)Math.Ceiling(hDif / dif);
            Console.WriteLine(num);
        }
    }
}

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

namespace CodeForces_652A
{
    class Program
    {
        static void Main(string[] args)
        {
            int h1, h2, u, d;
            string[] tempStr = Console.ReadLine().Split(' ');
            h1 = int.Parse(tempStr[0]);
            h2 = int.Parse(tempStr[1]);
            tempStr = Console.ReadLine().Split(' ');
            u = int.Parse(tempStr[0]);
            d = int.Parse(tempStr[1]);
            int curentCatPlace = h1;
            if(8*u + h1 > h2)
            {
                Console.WriteLine(0);
                return;
            }
            else
            {
                if (u < d)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }

            curentCatPlace += 8 * u;
            d += 12;
            u *= 12;
            float dif = u - d;
            float hDif = h2 - curentCatPlace;
            Console.WriteLine(Math.Floor(hDif / dif)+1);
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using System.Numerics;
using E = System.Linq.Enumerable;

namespace ProbA {
    class Program {
        protected IOHelper io;

        public Program(string inputFile, string outputFile) {
            io = new IOHelper(inputFile, outputFile, Encoding.Default);

            int h1 = io.NextInt(), h2 = io.NextInt();
            int a = io.NextInt(), b = io.NextInt();
            int days = 0, lastday = h1;
            while (h1 < h2) {
                h1 += 8 * a;
                if (h1 >= h2) break;
                h1 -= 12 * b;
                h1 += 4 * a;
                if (h1 >= h2) break;
                ++days;
                if (lastday >= h1) break;
            }
            if (lastday >= h1) io.WriteLine(-1);
            else io.WriteLine(days);
            io.Dispose();
        }

        static void Main(string[] args) {
            Program myProgram = new Program(null, null);
        }
    }

    class IOHelper : IDisposable {
        public StreamReader reader;
        public StreamWriter writer;

        public IOHelper(string inputFile, string outputFile, Encoding encoding) {
            if (inputFile == null)
                reader = new StreamReader(Console.OpenStandardInput(), encoding);
            else
                reader = new StreamReader(inputFile, encoding);

            if (outputFile == null)
                writer = new StreamWriter(Console.OpenStandardOutput(), encoding);
            else
                writer = new StreamWriter(outputFile, false, encoding);

            curLine = new string[] { };
            curTokenIdx = 0;
        }

        string[] curLine;
        int curTokenIdx;

        char[] whiteSpaces = new char[] { ' ', '\t', '\r', '\n' };

        public bool hasNext() {
            if (curTokenIdx >= curLine.Length) {
                //Read next line
                string line = reader.ReadLine();
                if (line != null)
                    curLine = line.Split(whiteSpaces, StringSplitOptions.RemoveEmptyEntries);
                else
                    curLine = new string[] { };
                curTokenIdx = 0;
            }

            return curTokenIdx < curLine.Length;
        }

        public string NextToken() {
            return hasNext() ? curLine[curTokenIdx++] : null;
        }

        public int NextInt() {
            return int.Parse(NextToken());
        }

        public double NextDouble() {
            string tkn = NextToken();
            return double.Parse(tkn, System.Globalization.CultureInfo.InvariantCulture);
        }

        public void Write(double val, int precision) {
            writer.Write(val.ToString("F" + precision, System.Globalization.CultureInfo.InvariantCulture));
        }

        public void Write(object stringToWrite) {
            writer.Write(stringToWrite);
        }

        public void WriteLine(double val, int precision) {
            writer.WriteLine(val.ToString("F" + precision, System.Globalization.CultureInfo.InvariantCulture));
        }

        public void WriteLine(object stringToWrite) {
            writer.WriteLine(stringToWrite);
        }

        public void Dispose() {
            try {
                if (reader != null) {
                    reader.Dispose();
                }
                if (writer != null) {
                    writer.Flush();
                    writer.Dispose();
                }
            } catch { };
        }

        public void Flush() {
            if (writer != null) {
                writer.Flush();
            }
        }
    }
}

using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Linq;
using System.Globalization;
using System.Threading;
using System.Web.Script.Serialization;

class Program
{
    private static void Main(string[] args)
    {
        long h1 = ReadInt();
        long h2 = ReadInt();
        long a = ReadInt();
        long b = ReadInt();

        h1 -= 4 * a;

        if (a <= b && (12 * a + h1) < h2)
        {
            Console.Write(-1);
            return;
        }

        if (a <= b)
        {
            Console.Write(0);
            return;
        }

        long d1 = (h2 - h1 - 12 * a);
        long d2 = (12 * (a - b));

        long days = (d1 + d2 - 1) / d2;

        Console.Write(days);
    }

    private static List<int>[] ReadGraph(int n, int m)
    {
        List<int>[] g = new List<int>[n + 1];
        for (int i = 0; i <= n; i++) g[i] = new List<int>();
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt() - 1;
            int b = ReadInt() - 1;

            g[a].Add(b);
            g[b].Add(a);
        }

        return g;
    }

    private static int[,] ReadGraphAsMatrix(int n, int m)
    {
        int[,] matrix = new int[n + 1, n + 1];
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt();
            int b = ReadInt();
            matrix[a, b] = matrix[b, a] = 1;
        }

        return matrix;
    }

    private static void Sort(ref int a, ref int b)
    {
        if (a > b) Swap(ref a, ref b);
    }

    private static void Swap(ref int a, ref int b)
    {
        int tmp = a;
        a = b;
        b = tmp;
    }

    private const int BufferSize = 1 << 16;
    private static StreamReader consoleReader;
    private static MemoryStream testData;

    private static int ReadInt()
    {
        int ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static ulong ReadULong()
    {
        ulong ans = 0;
        int chr;
        do
        {
            chr = consoleReader.Read();
            if (chr == -1)
                return 0;
        } while (chr < '0' || chr > '9');

        ans = (uint)(chr - '0');
        while (true)
        {
            chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans;
            ans = ans * 10 + (uint)(chr - '0');
        }
    }

    private static long ReadLong()
    {
        long ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static int[] ReadIntArray(int n)
    {
        int[] ans = new int[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadInt();
        return ans;
    }

    private static long[] ReadLongArray(int n)
    {
        long[] ans = new long[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadLong();
        return ans;
    }

    private static char[] ReadString()
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'a' || ans > 'z');

        List<char> s = new List<char>();
        do
        {
            s.Add((char)ans);
            ans = consoleReader.Read();
        } while (ans >= 'a' && ans <= 'z');

        return s.ToArray();
    }

    private static char[] ReadString(int n)
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'A' || ans > 'Z');

        char[] s = new char[n];
        int pos = 0;
        do
        {
            s[pos++] = (char)ans;
            if (pos == n) break;
            ans = consoleReader.Read();
        } while (ans >= 'A' && ans <= 'Z');

        return s;
    }

    private static char ReadLetter()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if ((ans >= 'a' && ans <= 'z') || (ans >= 'A' && ans <= 'Z'))
                return (char)ans;
        }
    }

    private static char ReadDigit()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if (ans >= '0' && ans <= '9')
                return (char)ans;
        }
    }

    private static int ReadDigitInt()
    {
        return ReadDigit() - (int)'0';
    }

    private static char ReadAnyChar()
    {
        return (char)consoleReader.Read();
    }

    private static string DoubleToString(double x)
    {
        return x.ToString(CultureInfo.InvariantCulture);
    }

    static Program()
    {
        //Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
        consoleReader = new StreamReader(Console.OpenStandardInput(BufferSize), Encoding.ASCII, false, BufferSize);
    }

    private static void PushTestData(string data)
    {
#if !ONLINE_JUDGE
        if (testData == null)
        {
            testData = new MemoryStream();
            consoleReader = new StreamReader(testData);
        }

        var pos = testData.Position;
        var bytes = Encoding.UTF8.GetBytes(data);
        testData.Write(bytes, 0, bytes.Length);
        testData.Flush();
        testData.Position = pos;
#endif
    }
}

using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Linq;
using System.Globalization;
using System.Threading;
using System.Web.Script.Serialization;

class Program
{
    private static void Main(string[] args)
    {
        long h1 = ReadInt();
        long h2 = ReadInt();
        long a = ReadInt();
        long b = ReadInt();

        h1 -= 4 * a;

        if (a <= b && (12 * a + h1) < h2)
        {
            Console.Write(-1);
            return;
        }

        if (a <= b)
        {
            Console.Write(0);
            return;
        }

        long d1 = (h2 - h1);
        long d2 = (12 * (a - b));

        long days = (d1 + d2 - 1) / d2;

        Console.Write(days);
    }

    private static List<int>[] ReadGraph(int n, int m)
    {
        List<int>[] g = new List<int>[n + 1];
        for (int i = 0; i <= n; i++) g[i] = new List<int>();
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt() - 1;
            int b = ReadInt() - 1;

            g[a].Add(b);
            g[b].Add(a);
        }

        return g;
    }

    private static int[,] ReadGraphAsMatrix(int n, int m)
    {
        int[,] matrix = new int[n + 1, n + 1];
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt();
            int b = ReadInt();
            matrix[a, b] = matrix[b, a] = 1;
        }

        return matrix;
    }

    private static void Sort(ref int a, ref int b)
    {
        if (a > b) Swap(ref a, ref b);
    }

    private static void Swap(ref int a, ref int b)
    {
        int tmp = a;
        a = b;
        b = tmp;
    }

    private const int BufferSize = 1 << 16;
    private static StreamReader consoleReader;
    private static MemoryStream testData;

    private static int ReadInt()
    {
        int ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static ulong ReadULong()
    {
        ulong ans = 0;
        int chr;
        do
        {
            chr = consoleReader.Read();
            if (chr == -1)
                return 0;
        } while (chr < '0' || chr > '9');

        ans = (uint)(chr - '0');
        while (true)
        {
            chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans;
            ans = ans * 10 + (uint)(chr - '0');
        }
    }

    private static long ReadLong()
    {
        long ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static int[] ReadIntArray(int n)
    {
        int[] ans = new int[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadInt();
        return ans;
    }

    private static long[] ReadLongArray(int n)
    {
        long[] ans = new long[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadLong();
        return ans;
    }

    private static char[] ReadString()
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'a' || ans > 'z');

        List<char> s = new List<char>();
        do
        {
            s.Add((char)ans);
            ans = consoleReader.Read();
        } while (ans >= 'a' && ans <= 'z');

        return s.ToArray();
    }

    private static char[] ReadString(int n)
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'A' || ans > 'Z');

        char[] s = new char[n];
        int pos = 0;
        do
        {
            s[pos++] = (char)ans;
            if (pos == n) break;
            ans = consoleReader.Read();
        } while (ans >= 'A' && ans <= 'Z');

        return s;
    }

    private static char ReadLetter()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if ((ans >= 'a' && ans <= 'z') || (ans >= 'A' && ans <= 'Z'))
                return (char)ans;
        }
    }

    private static char ReadDigit()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if (ans >= '0' && ans <= '9')
                return (char)ans;
        }
    }

    private static int ReadDigitInt()
    {
        return ReadDigit() - (int)'0';
    }

    private static char ReadAnyChar()
    {
        return (char)consoleReader.Read();
    }

    private static string DoubleToString(double x)
    {
        return x.ToString(CultureInfo.InvariantCulture);
    }

    static Program()
    {
        //Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
        consoleReader = new StreamReader(Console.OpenStandardInput(BufferSize), Encoding.ASCII, false, BufferSize);
    }

    private static void PushTestData(string data)
    {
#if !ONLINE_JUDGE
        if (testData == null)
        {
            testData = new MemoryStream();
            consoleReader = new StreamReader(testData);
        }

        var pos = testData.Position;
        var bytes = Encoding.UTF8.GetBytes(data);
        testData.Write(bytes, 0, bytes.Length);
        testData.Flush();
        testData.Position = pos;
#endif
    }
}

using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Linq;
using System.Globalization;
using System.Threading;
using System.Web.Script.Serialization;

class Program
{
    private static void Main(string[] args)
    {
        long h1 = ReadInt();
        long h2 = ReadInt();
        long a = ReadInt();
        long b = ReadInt();

        h1 += 8 * a;

        if (a <= b && h1 < h2)
        {
            Console.Write(-1);
            return;
        }

        if (a <= b)
        {
            Console.Write(0);
            return;
        }

        long d1 = (h2 - h1);
        long d2 = (12 * (a - b));

        long days = (d1 + d2 - 1) / d2;

        Console.Write(days);
    }

    private static List<int>[] ReadGraph(int n, int m)
    {
        List<int>[] g = new List<int>[n + 1];
        for (int i = 0; i <= n; i++) g[i] = new List<int>();
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt() - 1;
            int b = ReadInt() - 1;

            g[a].Add(b);
            g[b].Add(a);
        }

        return g;
    }

    private static int[,] ReadGraphAsMatrix(int n, int m)
    {
        int[,] matrix = new int[n + 1, n + 1];
        for (int i = 0; i < m; i++)
        {
            int a = ReadInt();
            int b = ReadInt();
            matrix[a, b] = matrix[b, a] = 1;
        }

        return matrix;
    }

    private static void Sort(ref int a, ref int b)
    {
        if (a > b) Swap(ref a, ref b);
    }

    private static void Swap(ref int a, ref int b)
    {
        int tmp = a;
        a = b;
        b = tmp;
    }

    private const int BufferSize = 1 << 16;
    private static StreamReader consoleReader;
    private static MemoryStream testData;

    private static int ReadInt()
    {
        int ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static ulong ReadULong()
    {
        ulong ans = 0;
        int chr;
        do
        {
            chr = consoleReader.Read();
            if (chr == -1)
                return 0;
        } while (chr < '0' || chr > '9');

        ans = (uint)(chr - '0');
        while (true)
        {
            chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans;
            ans = ans * 10 + (uint)(chr - '0');
        }
    }

    private static long ReadLong()
    {
        long ans = 0;
        int mul = 1;
        do
        {
            ans = consoleReader.Read();
            if (ans == -1)
                return 0;
            if (ans == '-') mul = -1;
        } while (ans < '0' || ans > '9');

        ans -= '0';
        while (true)
        {
            int chr = consoleReader.Read();
            if (chr < '0' || chr > '9')
                return ans * mul;
            ans = ans * 10 + chr - '0';
        }
    }

    private static int[] ReadIntArray(int n)
    {
        int[] ans = new int[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadInt();
        return ans;
    }

    private static long[] ReadLongArray(int n)
    {
        long[] ans = new long[n];
        for (int i = 0; i < n; i++)
            ans[i] = ReadLong();
        return ans;
    }

    private static char[] ReadString()
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'a' || ans > 'z');

        List<char> s = new List<char>();
        do
        {
            s.Add((char)ans);
            ans = consoleReader.Read();
        } while (ans >= 'a' && ans <= 'z');

        return s.ToArray();
    }

    private static char[] ReadString(int n)
    {
        int ans;

        do
        {
            ans = consoleReader.Read();
        } while (ans < 'A' || ans > 'Z');

        char[] s = new char[n];
        int pos = 0;
        do
        {
            s[pos++] = (char)ans;
            if (pos == n) break;
            ans = consoleReader.Read();
        } while (ans >= 'A' && ans <= 'Z');

        return s;
    }

    private static char ReadLetter()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if ((ans >= 'a' && ans <= 'z') || (ans >= 'A' && ans <= 'Z'))
                return (char)ans;
        }
    }

    private static char ReadDigit()
    {
        while (true)
        {
            int ans = consoleReader.Read();
            if (ans >= '0' && ans <= '9')
                return (char)ans;
        }
    }

    private static int ReadDigitInt()
    {
        return ReadDigit() - (int)'0';
    }

    private static char ReadAnyChar()
    {
        return (char)consoleReader.Read();
    }

    private static string DoubleToString(double x)
    {
        return x.ToString(CultureInfo.InvariantCulture);
    }

    static Program()
    {
        //Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
        consoleReader = new StreamReader(Console.OpenStandardInput(BufferSize), Encoding.ASCII, false, BufferSize);
    }

    private static void PushTestData(string data)
    {
#if !ONLINE_JUDGE
        if (testData == null)
        {
            testData = new MemoryStream();
            consoleReader = new StreamReader(testData);
        }

        var pos = testData.Position;
        var bytes = Encoding.UTF8.GetBytes(data);
        testData.Write(bytes, 0, bytes.Length);
        testData.Flush();
        testData.Position = pos;
#endif
    }
}