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

namespace ConsoleApplication2
{
    class Program
    {
        static int kachestvo(int n)
        {
            if (n == 0 || n == 2 || n == 9 || n == 6) return 2;
            else
                if (n == 1) return 7;
                else
                        if (n == 3 || n == 4) return 3;
                        else
                            if (n == 5) return 4;
                            else
                                if (n == 7) return 5;
                                else return 1;

        }
        static void Main(string[] args)
        {
            int n = Convert.ToInt32(Console.ReadLine());
            Console.WriteLine(kachestvo(n / 10) * kachestvo(n % 10));

        }
    }
}

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

namespace ConsoleApplication10
{
    class Program
    {
        static void Main(string[] args)
        {
            int a = Convert.ToInt32(Console.ReadLine());
            int b = a % 10;
            int c = ((a % 100) - b) / 10;
            int [] ar = { 2,7,2,3,3,4,2,5,1,2 };
            Console.WriteLine(ar[b] * ar[c]);
            Console.ReadLine();
        }
    }
}

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

namespace DigitalCounter
{
    class Program
    {
        static bool CanBe(List<short> faulty, List<short> correct)
        {
            bool valid = true;
            for (int i = 0; i < 7 && valid; i++)
            {
                if (correct[i] - faulty[i] < 0)
                    valid = false;
            }
            return (valid) ? true : false;
        }

        static void Main(string[] args)
        {
            //initializing correspondence table
            var digitStickTable = new Dictionary<char, List<short>>();
            digitStickTable.Add('0', new List<short>() { 1, 1, 1, 1, 1, 1, 0 });
            digitStickTable.Add('1', new List<short>() { 0, 1, 1, 0, 0, 0, 0 });
            digitStickTable.Add('2', new List<short>() { 1, 1, 0, 1, 1, 0, 1 });
            digitStickTable.Add('3', new List<short>() { 1, 1, 1, 1, 0, 0, 1 });
            digitStickTable.Add('4', new List<short>() { 0, 1, 1, 0, 0, 1, 1 });
            digitStickTable.Add('5', new List<short>() { 1, 0, 1, 1, 0, 1, 1 });
            digitStickTable.Add('6', new List<short>() { 1, 0, 1, 1, 1, 1, 1 });
            digitStickTable.Add('7', new List<short>() { 1, 1, 1, 0, 0, 0, 0 });
            digitStickTable.Add('8', new List<short>() { 1, 1, 1, 1, 1, 1, 1 });
            digitStickTable.Add('9', new List<short>() { 1, 1, 1, 1, 0, 1, 1 });

            //reading user entries
            char[] number = Console.ReadLine().ToCharArray();
            int result = 0;
            foreach (char digit in digitStickTable.Keys)
                if (CanBe(digitStickTable[number[0]], digitStickTable[digit]))
                {
                    result++;
                }

            if (number[1] == number[0])
                result *= result;
            else
            {
                int secondDigit = 0;
                foreach (char digit in digitStickTable.Keys)
                    if (CanBe(digitStickTable[number[1]], digitStickTable[digit]))
                    {
                        secondDigit++;
                    }
                if (secondDigit > 0 && result > 0) result *= secondDigit;
                else result += secondDigit;
            }
            Console.WriteLine(result);
        }
    }
}

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

namespace ConsoleApplicationOLIMP
{
    class Program
    {
        static int Main(string[] args)
        {
            int[] a = {2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
            int b;
            b = int.Parse(Console.ReadLine());
            Console.WriteLine(a[b % 10]*a[b / 10]);
            return 0;
        }
    }
}

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

namespace Round_282
{
    class Program
    {
        static void Main(string[] args)
        {
            Digit g = new Digit();
            g.Test();
        }
    }
    class Digit
    {
        int Transform(int a, int b)
        {
            int res=0;
            switch (b)//transform to
            {
                case 0:
                    switch(a)//transform from
                    {
                        case 0: res= 1;break;
                        case 8: res=1 ;break;
                    }
                    break;
                case 1:
                    switch (a)
                    {
                        case 0: res= 1;break;
                        case 1: res= 1;break;
                        case 3: res= 1;break;
                        case 4: res= 1;break;
                        case 7:res= 1;break;
                        case 8: res= 1;break;
                        case 9: res= 1;break;
                    }
                    break;

                case 2:
                    switch(a)
                    {
                        case 2: res= 1;break;
                        case 8: res= 1;break;
                    }
                    break;

                case 3:
                    switch(a)
                    {
                        case 3: res= 1;break;
                        case 8: res= 1;break;
                        case 9: res= 1;break;
                    }
                    break;

                case 4:
                    switch(a)
                    {
                        case 4: return 1;
                        case 8: return 1;
                        case 9: return 1;
                    }
                    break;

                case 5:
                    switch (a)
                    {
                        case 5: return 1;
                        case 6: return 1;
                        case 8: return 1;
                        case 9: return 1;
                    }
                    break;

                case 6:
                        switch (a)
                        {
                            case 6: return 1;
                            case 8: return 1;
                        }
                        break;

                case 7:
                    switch(a)
                    {
                        case 0: return 1;
                        case 3: return 1;
                        case 7:return 1;
                        case 8:return 1;
                        case 9: return 1;
                    }
                    break;

                case 8:
                    switch(a)
                    {
                        case 8:return 1;
                    }
                    break;

                case 9:
                    switch(a)
                    {
                        case 8: return 1;
                        case 9: return 1;
                    }
                    break;

            }
            return res;
        }
        int NumGood(int b)
        {
            int cnt = 0;
            for(int i=0;i<10;i++)
            {
                cnt += Transform(i, b);
            }
            return cnt;
        }
        public void Test()
        {
            int nn = int.Parse(Console.ReadLine());
            //int nn = 73;
            int n1 = NumGood(nn / 10);
            int n2 = NumGood(nn % 10);
            Console.WriteLine( (n1) * (n2));
        }
    }
}

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

namespace ConsoleApplication4
{
    class Program
    {
        static void Main(string[] args)
        {
            string input = Console.ReadLine();
            int n = int.Parse(input);
            int a = n / 10;
            int b = n % 10;
            int res = 1;
            if (a == 0) res *= 2;
            if (a == 1) res *= 7;
            if (a == 2) res *= 2;
            if (a == 3) res *= 3;
            if (a == 4) res *= 3;
            if (a == 5) res *= 4;
            if (a == 6) res *= 2;
            if (a == 7) res *= 5;
            if (a == 8) res *= 1;
            if (a == 9) res *= 2;
            if (b == 0) res *= 2;
            if (b == 1) res *= 7;
            if (b == 2) res *= 2;
            if (b == 3) res *= 3;
            if (b == 4) res *= 3;
            if (b == 5) res *= 4;
            if (b == 6) res *= 2;
            if (b == 7) res *= 5;
            if (b == 8) res *= 1;
            if (b == 9) res *= 2;
            Console.WriteLine(res);

        }
    }
}

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

namespace prA {

    class Program {
#if ONLINE_JUDGE
        private static readonly StreamReader reader = new StreamReader(Console.OpenStandardInput(1024 * 10), System.Text.Encoding.ASCII, false, 1024 * 10);
        private static readonly StreamWriter writer = new StreamWriter(Console.OpenStandardOutput(1024 * 10), System.Text.Encoding.ASCII, 1024 * 10);
#else
        private static readonly StreamWriter writer = new StreamWriter("output");
        private static readonly StreamReader reader = new StreamReader("input");
#endif
        static void Main(string[] args) {
            int[] d = {2, 1 + 1 + 1 + 1 + 1 + 1 + 1, 1 + 1, 1 + 1 + 1, 1 + 1 + 1, 1 + 1 + 1 + 1, 1 + 1, 1 + 1 + 1 + 1 + 1, 1, 1 + 1};
            string s = reader.ReadLine();
            int ans = d[s[0] - '0'] * d[s[1] - '0'];
            writer.Write(ans);
            writer.Flush();
#if !ONLINE_JUDGE
            writer.Close();
#endif
        }
        private static int Next() {
            int c;
            int res = 0;
            do {
                c = reader.Read();
                if(c == -1)
                    return res;
            } while(c != '-' && (c < '0' || c > '9'));
            int sign = 1;
            if(c == '-') {
                sign = -1;
                c = reader.Read();
            }
            res = c - '0';
            while(true) {
                c = reader.Read();
                if(c < '0' || c > '9')
                    return res * sign;
                res *= 10;
                res += c - '0';
            }
        }
    }
}

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

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int f = Convert.ToInt32(Console.ReadLine());
            int f1 = f / 10;
            int f2 = f % 10;
            int[] p = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };

            Console.WriteLine(p[f1] * p[f2]);
            Console.ReadLine();
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main()
        {
            //int t = int.Parse(Console.ReadLine());
            int a = Console.Read() - '0',
                b = Console.Read() - '0';

            var transform = new List<int>
            {
                2,//0
                7,//1
                2,//2
                3,//3
                3,//4
                4,//5
                2,//6
                5,//7
                1,//8
                2 //9
            };

            Console.WriteLine(transform[a] * transform[b]);
        }
    }

}

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

namespace ConsoleApplication10
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Convert.ToInt32(Console.ReadLine());
            int b = n % 10;
            int a = (n - b) / 10;
            int[] s = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            Console.WriteLine(s[a]*s[b]);
            Console.ReadLine();

        }
    }
}

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

// (づ°ω°)づﾐ★゜・。。・゜゜・。。・゜☆゜・。。・゜゜・。。・゜
public class Solver
{
    public object Solve()
    {
        var a = new[] {2, 7, 2, 3, 3, 4, 2, 5, 1, 2};

        int n = ReadInt();
        return a[n / 10] * a[n % 10];

        return null;
    }

    #region Main

    protected static TextReader reader;
    protected static TextWriter writer;

    static void Main()
    {
#if DEBUG
        reader = new StreamReader("..\\..\\input.txt");
        writer = Console.Out;
        //writer = new StreamWriter("..\\..\\output.txt");
#else
        reader = new StreamReader(Console.OpenStandardInput());
        writer = new StreamWriter(Console.OpenStandardOutput());
        //reader = new StreamReader("improvements.in");
        //writer = new StreamWriter("improvements.out");
#endif
        try
        {
            object result = new Solver().Solve();
            if (result != null)
                writer.WriteLine(result);
        }
        catch (Exception ex)
        {
#if DEBUG
            Console.WriteLine(ex);
#else
            Console.WriteLine(ex);
            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<T>(params T[] array)
    {
        WriteArray(array);
    }

    public static void WriteLines<T>(IEnumerable<T> array)
    {
        foreach (var a in array)
            writer.WriteLine(a);
    }

    #endregion
}

using System;
class Program
{
    static void Main()
    {
        var ar = new int[] { 126, 48, 109, 121, 51, 91, 95, 112, 127, 123 };
        var an = 0;
        var bn = 0;
        var d = int.Parse(Console.ReadLine());
        var b = ar[d % 10];
        d /= 10;
        var a = ar[d % 10];
        foreach (var item in ar)
        {
            if ((a & item) >= a)
            {
                an++;
            }
            if ((b & item) >= b)
            {
                bn++;
            }
        }
        Console.WriteLine(an * bn);
    }
}

using System;
namespace CodeForces{
    class Contest {
        static void Main(string [] Args) {
            string s = Console.ReadLine();
            int[] dig = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
            Console.Write(dig[s[0]-'0']*dig[s[1]-'0']);
        }
    }
}

using System;
namespace CodeForces{
    class Contest {
        static void Main(string [] Args) {
            string s = Console.ReadLine();
            int[] dig = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
            int a = s[0]-'0';
            int b = s[1]-'0';
            Console.Write(string.Format("{0}", dig[a] * dig[b]));
        }
    }
}

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

namespace ConsoleApplication2
{
    class Program
    {
        static void Main(string[] args)
        {
            int a = Convert.ToInt32(Console.ReadLine());
           int b=a%10 ;
           int c = (a - b) / 10;
           int[] ar = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
           Console.WriteLine(ar[b] * ar[c]);
           Console.ReadLine();

        }
    }
}

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

namespace main
{
    class Program
    {
        static void Main()
        {
            int[] a = new int[10] { 2,7,2,3,3,4,2,5,1,2 };
            int x = Convert.ToInt32(Console.ReadLine());
            int q = x/10;
            int t = x%10;
            Console.WriteLine(a[q]*a[t]);

            //int p = Convert.ToInt32(Console.ReadLine());

            //Console.WriteLine(str1);
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net.Sockets;
using System.Text;
using System.Threading.Tasks;
using System.IO;
using System.Threading;

namespace IntoToCSharp
{
    class Source
    {
        static void Main(string[] args)
        {
            Dictionary<int, int> dic = new Dictionary<int,int> ();
            dic.Add(0, 2);
            dic.Add(1, 7);
            dic.Add(2, 2);
            dic.Add(3, 3);
            dic.Add(4, 3);
            dic.Add(5, 4);
            dic.Add(6, 2);
            dic.Add(7, 5);
            dic.Add(8, 1);
            dic.Add(9, 2);

            string s = Console.ReadLine();

            int ans = dic[(int)s[0] - 48];
            ans *= dic[(int)s[1] - 48];

            Console.Write(ans);

        }

    }

}

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

namespace codeforces
{
	class Program
	{
		public class User
		{
			public int c;

			public int r;
		}

		public class Point
		{
			public int x;

			public double p;
		}

		public class Comparer : IComparer<User>
		{
			public int Compare(User x, User y)
			{
				if (x.c < y.c || (x.c == y.c && x.r < y.r))
					return -1;
				return 1;
			}
		}

		public static long getGcd(long a, long b)
		{
			if (b == 0)
				return a;
			return getGcd(b, a % b);
		}

		public static void WriteYESNO(bool x, string yes = "YES", string no = "NO")
		{
			if (x)
				Console.WriteLine(yes);
			else
			{
				Console.WriteLine(no);
			}
		}

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

		public static List<int> getList()
		{
			var s = Console.ReadLine();
			return s.Split(' ').Select(int.Parse).ToList();
		}

		public static int Min(int x, int y)
		{
			return Math.Min(x, y);
		}

		public static int Max(int x, int y)
		{
			return Math.Max(x, y);
		}

		public static int Abs(int x)
		{
			return Math.Abs(x);
		}

		public static int getInt()
		{
			var s = Console.ReadLine();
			return int.Parse(s);
		}

		public static bool Equal(int x, int y, int x1, int y1)
		{
			return x == x1 && y == y1;
		}

		public class Vertex
		{
			public List<int> edges;

			public int ct;

			public Vertex()
			{
				ct = 0;
				edges = new List<int>();
				for (var i = 0; i < 26; ++i)
					edges.Add(0);
			}
		}

		private static void Main(string[] args)
		{
/*			var input = new StreamReader("input.txt");
			var output = new StreamWriter("output.txt");*/

			var n = getInt();
			var a = n/10;
			var b = n%10;
			var ct1 = 0;
			var ct2 = 0;
			if (a == 0)
			{
				ct1 = 2;
			}
			if (a == 1)
			{
				ct1 = 7;
			}
			if (a == 2)
				ct1 = 2;
			if (a == 3)
				ct1 = 3;
			if (a == 4)
				ct1 = 3;
			if (a == 5)
				ct1 = 4;
			if (a == 6)
				ct1 = 2;
			if (a == 7)
				ct1 = 5;
			if (a == 8)
				ct1 = 1;
			if (a == 9)
				ct1 = 2;
			if (b == 0)
			{
				ct2 = 2;
			}
			if (b == 1)
			{
				ct2 = 7;
			}
			if (b == 2)
				ct2 = 2;
			if (b == 3)
				ct2 = 3;
			if (b == 4)
				ct2 = 3;
			if (b == 5)
				ct2 = 4;
			if (b == 6)
				ct2 = 2;
			if (b == 7)
				ct2 = 5;
			if (b == 8)
				ct2 = 1;
			if (b == 9)
				ct2 = 2;
			Console.WriteLine(ct1 * ct2);
			/*			input.Close();
			output.Close();*/
		}
	}
}

using System;
class CFR282D2A
{
    private static int[] a = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
    static void Main(string[] args)
    {
        string data = Console.ReadLine();
        int a1 = a[int.Parse(data[0] + "")];
        int a2 = a[int.Parse(data[1] + "")];
        Console.WriteLine(a1 * a2);
    }
}

using System;

namespace CSharp
{
    public class _495A
    {
        static int[] map = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };

        public static void Main()
        {
            int n = int.Parse(Console.ReadLine());
            Console.WriteLine(map[n / 10] * map[n % 10]);
        }
    }
}

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

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

            int[] options = new int[] {
                2,
                7,
                2,
                3,
                3,
                4,
                2,
                5,
                1,
                2
            };

            int firstDigit = n / 10;
            int secondDigit = n % 10;

            Console.WriteLine(options[firstDigit] * options[secondDigit]);
        }
    }
}

using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Security.Policy;

namespace ConsoleApplication3
{
    internal class NumberIndicator
    {
        public static List<byte[]> Numbers = new List<byte[]>
        {
            new byte[] {1, 1, 1, 1, 1, 1, 0},
            new byte[] {0, 0, 1, 1, 0, 0, 0},
            new byte[] {0, 1, 1, 0, 1, 1, 1},
            new byte[] {0, 1, 1, 1, 1, 0, 1},
            new byte[] {1, 0, 1, 1, 0, 0, 1},
            new byte[] {1, 1, 0, 1, 1, 0, 1},
            new byte[] {1, 1, 0, 1, 1, 1, 1},
            new byte[] {0, 1, 1, 1, 0, 0, 0},
            new byte[] {1, 1, 1, 1, 1, 1, 1},
            new byte[] {1, 1, 1, 1, 1, 0, 1},
        };

        public static int FindGoodNumbers(int first, int second)
        {
            var firstBinaryNum = Numbers.ElementAt(first);
            var secondBinaryNum = Numbers.ElementAt(second);

            var firstResult = 0;
            var secondResult = 0;
            foreach (var number in Numbers)
            {
                var addFirst = true;
                var addSecond = true;
                for (var i = 0; i < number.Length; i++)
                {
                    if (firstBinaryNum[i] == 1 && number[i] != 1)
                    {
                        addFirst = false;
                    }
                    if (secondBinaryNum[i] == 1 && number[i] != 1)
                    {
                        addSecond = false;
                    }
                }
                if (addFirst)
                {
                    firstResult++;
                }
                if (addSecond)
                {
                    secondResult++;
                }
            }
            return firstResult*secondResult;
        }

        private static void Main(string[] args)
        {
            var stringNumber = Console.ReadLine();
            if (stringNumber == null) return;
            var result = FindGoodNumbers((int) Char.GetNumericValue(stringNumber[0]),
                (int) Char.GetNumericValue(stringNumber[1]));
            Console.WriteLine(result);
        }
    }
}

using System;

namespace Grimlor.CodeForces
{
    class DigitalRoomForError
    {
        private static int[] _possibleDigits = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
        public static void Main(string[] args)
        {
            string elevatorDigits = Console.ReadLine();
            int firstDigit = int.Parse(elevatorDigits[0].ToString());
            int secondDigit = int.Parse(elevatorDigits[1].ToString());
            Console.WriteLine(_possibleDigits[firstDigit] * _possibleDigits[secondDigit]);
        }
    }
}

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

namespace _13._12
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] a = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            string s = Console.ReadLine();
            if (s.Length == 2 && s[0] >= '0' && s[0] <= '9' && s[1] >= '0' && s[1] <= '9')
            {
                int a1 = Convert.ToInt32(s[0].ToString());
                int a2 = Convert.ToInt32(s[1].ToString());
                Console.WriteLine(a[a1] * a[a2]);
            }
        }
    }
}

using System;
using System.Collections.Generic;
class Program
    {
        public static void Main(string[] args)
        {
            string input = Console.ReadLine();
            Dictionary<char, int> dictionary = new Dictionary<char, int>();
            dictionary.Add('0', 2);
            dictionary.Add('1', 7);
            dictionary.Add('2', 2);
            dictionary.Add('3', 3);
            dictionary.Add('4', 3);
            dictionary.Add('5', 4);
            dictionary.Add('6', 2);
            dictionary.Add('7', 5);
            dictionary.Add('8', 1);
            dictionary.Add('9', 2);
            Console.WriteLine((dictionary[input[0]] * dictionary[input[1]]));
        }
    }

using System;

namespace DigitalCounter
{
    partial class DigitalCounter
    {
        static void Main(string[] args)
        {
            string number;
            int count1, count2;

            number = ReadLine();

            count1 = GetSticksCount(number[0] - 48).Length;
            count2 = GetSticksCount(number[1] - 48).Length;

            Console.WriteLine(count1 * count2);
        }

        private static int[] GetSticksCount(int number)
        {
            switch (number)
            {
                case 0:
                    return new[] { 0, 8 };

                case 1:
                    return new[] { 0, 1, 3, 4, 7, 8, 9 };

                case 2:
                    return new[] { 2, 8 };

                case 3:
                case 4:
                    return new[] { 3, 8, 9 };

                case 5:
                    return new[] { 5, 6, 8, 9 };

                case 6:
                    return new[] { 6, 8 };

                case 7:
                    return new[] { 0, 3, 7, 8, 9 };

                default:
                    return new[] { 8 };

                case 9:
                    return new[] { 8, 9 };
            }
        }
    }

    partial class DigitalCounter
    {
        static string[] tokens = new string[0];
        static int cur_token = 0;

        static void ReadArray(char sep)
        {
            cur_token = 0;
            tokens = Console.ReadLine().Split(sep);
        }

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

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

        static int NextInt()
        {
            if (cur_token == tokens.Length)
                ReadArray(' ');
            return int.Parse(tokens[cur_token++]);
        }

        static long NextLong()
        {
            if (cur_token == tokens.Length)
                ReadArray(' ');
            return long.Parse(tokens[cur_token++]);
        }

        static double NextDouble()
        {
            if (cur_token == tokens.Length)
                ReadArray(' ');
            return double.Parse(tokens[cur_token++]);
        }

        static decimal NextDecimal()
        {
            if (cur_token == tokens.Length)
                ReadArray(' ');
            return decimal.Parse(tokens[cur_token++]);
        }

        static string NextToken()
        {
            if (cur_token == tokens.Length)
                ReadArray(' ');
            return tokens[cur_token++];
        }

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

namespace topCoder
{
	using System;
	using System.Collections.Generic;

	class p1
	{
		public void foo()
		{
			int[] n = new int[] { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };

			string x = System.Console.ReadLine();
			int r = n[int.Parse(x[0].ToString())] * n[int.Parse(x[1].ToString())];
			System.Console.WriteLine(r);
		}
		static void Main(string[] args)
		{
			p1 o = new p1();
			o.foo();

			//Console.ReadLine();
		}
	}
}

using System;
using System.Collections.Generic;
using System.Linq;
using Solver.Ex;
using Debug = System.Diagnostics.Debug;
using Watch = System.Diagnostics.Stopwatch;
using StringBuilder = System.Text.StringBuilder;
using System.Numerics;
namespace Solver
{
    public class Solver
    {
        public void Solve()
        {
            var n = sc.Char(2);
            int[] a = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            var ans = 1;
            for (int i = 0; i < 2; i++)
                ans *= a[n[i] - '0'];
            IO.Printer.Out.WriteLine(ans);
        }

        internal IO.StreamScanner sc;
        static T[] Enumerate<T>(int n, Func<int, T> f) { var a = new T[n]; for (int i = 0; i < n; i++) a[i] = f(i); return a; }
    }

    #region Main and Settings
    static class Program
    {
        static void Main(string[] arg)
        {
#if DEBUG
            var errStream = new System.IO.FileStream(@"..\..\dbg.out", System.IO.FileMode.Create, System.IO.FileAccess.Write, System.IO.FileShare.ReadWrite);
            Debug.Listeners.Add(new System.Diagnostics.TextWriterTraceListener(errStream, "debugStream"));
            Debug.AutoFlush = false;
            var sw = new Watch(); sw.Start();
            IO.Printer.Out.AutoFlush = true;
            try
            {
#endif

                var solver = new Solver();
                solver.sc = new IO.StreamScanner(Console.OpenStandardInput());
                solver.Solve();
                IO.Printer.Out.Flush();
#if DEBUG
            }
            catch (Exception ex)
            {
                Console.Error.WriteLine(ex.Message);
                Console.Error.WriteLine(ex.StackTrace);
            }
            finally
            {
                sw.Stop();
                Console.ForegroundColor = ConsoleColor.Green;
                Console.Error.WriteLine("Time:{0}ms", sw.ElapsedMilliseconds);
                Debug.Close();
                System.Threading.Thread.Sleep(System.Threading.Timeout.Infinite);
            }
#endif
        }

    }
    #endregion
}

#region IO Helper
namespace Solver.IO
{
    public class Printer : System.IO.StreamWriter
    {
        static Printer()
        {
            Out = new Printer(Console.OpenStandardOutput()) { AutoFlush = false };
#if DEBUG
            Error = new Printer(Console.OpenStandardError()) { AutoFlush = true };
#else
            Error = new Printer(System.IO.Stream.Null) { AutoFlush = false };
#endif
        }
        public static Printer Out { get; set; }
        public static Printer Error { get; set; }
        public override IFormatProvider FormatProvider { get { return System.Globalization.CultureInfo.InvariantCulture; } }
        public Printer(System.IO.Stream stream) : base(stream, new System.Text.UTF8Encoding(false, true)) { }
        public Printer(System.IO.Stream stream, System.Text.Encoding encoding) : base(stream, encoding) { }
        public void Write<T>(string format, IEnumerable<T> source) { base.Write(format, source.OfType<object>().ToArray()); }
        public void WriteLine<T>(string format, IEnumerable<T> source) { base.WriteLine(format, source.OfType<object>().ToArray()); }
    }
    public class StreamScanner
    {
        public StreamScanner(System.IO.Stream stream) { iStream = stream; }
        private readonly System.IO.Stream iStream;
        private readonly byte[] buf = new byte[1024];
        private int len, ptr;
        private bool eof = false;
        public bool IsEndOfStream { get { return eof; } }
        const byte lb = 33, ub = 126, el = 10, cr = 13;
        public byte read()
        {
            if (eof) throw new System.IO.EndOfStreamException();
            if (ptr >= len) { ptr = 0; if ((len = iStream.Read(buf, 0, 1024)) <= 0) { eof = true; return 0; } }
            return buf[ptr++];
        }
        public char Char() { byte b = 0; do b = read(); while (b < lb || ub < b); return (char)b; }
        public char[] Char(int n) { var a = new char[n]; for (int i = 0; i < n; i++) a[i] = Char(); return a; }
        public char[][] Char(int n, int m) { var a = new char[n][]; for (int i = 0; i < n; i++) a[i] = Char(m); return a; }
        public string Scan()
        {
            if (eof) throw new System.IO.EndOfStreamException();
            StringBuilder sb = null;
            var enc = System.Text.UTF8Encoding.Default;
            do
            {
                for (; ptr < len && (buf[ptr] < lb || ub < buf[ptr]); ptr++) ;
                if (ptr < len) break;
                ptr = 0;
                if ((len = iStream.Read(buf, 0, 1024)) <= 0) { eof = true; return ""; }
            } while (true);
            do
            {
                var f = ptr;
                for (; ptr < len; ptr++)
                    if (buf[ptr] < lb || ub < buf[ptr])
                    //if (buf[ptr] == cr || buf[ptr] == el)
                    {
                        string s;
                        if (sb == null) s = enc.GetString(buf, f, ptr - f);
                        else { sb.Append(enc.GetChars(buf, f, ptr - f)); s = sb.ToString(); }
                        ptr++; return s;
                    }
                if (sb == null) sb = new StringBuilder(enc.GetString(buf, f, len - f));
                else sb.Append(enc.GetChars(buf, f, len - f));
                ptr = 0;

            }
            while (!eof && (len = iStream.Read(buf, 0, 1024)) > 0);
            eof = true; return (sb != null) ? sb.ToString() : "";
        }
        public long Long()
        {
            long ret = 0; byte b = 0; bool isMynus = false;
            const byte zr = 48, nn = 57, my = 45;
            do b = read();
            while (b != my && (b < zr || nn < b));
            if (b == my) { isMynus = true; b = read(); }
            for (; true; b = read())
                if (b < zr || nn < b)
                    return isMynus ? -ret : ret;
                else ret = ret * 10 + b - zr;
        }
        public int Integer()
        {
            int ret = 0; byte b = 0; bool isMynus = false;
            const byte zr = 48, nn = 57, my = 45;
            do b = read();
            while (b != my && (b < zr || nn < b));
            if (b == my) { isMynus = true; b = read(); }
            for (; true; b = read())
                if (b < zr || nn < b)
                    return isMynus ? -ret : ret;
                else ret = ret * 10 + b - zr;
        }
        public double Double() { return double.Parse(Scan(), System.Globalization.CultureInfo.InvariantCulture); }
        public string[] Scan(int n) { var a = new string[n]; for (int i = 0; i < n; i++) a[i] = Scan(); return a; }
        public double[] Double(int n) { var a = new double[n]; for (int i = 0; i < n; i++) a[i] = Double(); return a; }
        public int[] Integer(int n) { var a = new int[n]; for (int i = 0; i < n; i++) a[i] = Integer(); return a; }
        public long[] Long(int n) { var a = new long[n]; for (int i = 0; i < n; i++)a[i] = Long(); return a; }
        public void Flush() { iStream.Flush(); }
    }
}
#endregion
#region Extension
namespace Solver.Ex
{
    static public partial class EnumerableEx
    {
        static public string AsString(this IEnumerable<char> ie) { return new string(ie.ToArray()); }
        static public string AsJoinedString<T>(this IEnumerable<T> ie, string st = " ") { return string.Join(st, ie); }

    }
}
#endregion

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

namespace ConsoleApplication25
{
    class Program
    {
        static void Main(string[] args)
        {
           string s = Console.ReadLine();
            int[] a = new int[] { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };

            if (s.Length == 2 && s[0] >= '0' && s[0] <= '9' && s[1] >= '0' && s[1] <= '9')
            {
                int a1 = Convert.ToInt32(s[0].ToString());
                int a2 = Convert.ToInt32(s[1].ToString());
                Console.WriteLine(a[a1] * a[a2]);
            }
                Console.ReadLine();
        }
    }
}

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

namespace A
{
    class Program
    {
        static void Main(string[] args)
        {
            string s;
            s = Console.ReadLine();
            char d, f;
            d = s[0];
            f = s[1];
            int a = (int)Char.GetNumericValue(d);
            int b = (int)Char.GetNumericValue(f);
            if (a == b)
            {
                if (a == 0) a = 2;
                else if (a == 1) a = 7;
                else if (a == 2) a = 2;
                else if (a == 3) a = 3;
                else if (a == 4) a = 3;
                else if (a == 5) a = 4;
                else if (a == 6) a = 2;
                else if (a == 7) a = 5;
                else if (a == 8) a = 1;
                else if (a == 9) a = 2;
                Console.WriteLine(a*a);
            }
            else
            {
                if (a == 0) a = 2;
                else if (a == 1) a = 7;
                else if (a == 2) a = 2;
                else if (a == 3) a = 3;
                else if (a == 4) a = 3;
                else if (a == 5) a = 4;
                else if (a == 6) a = 2;
                else if (a == 7) a = 5;
                else if (a == 8) a = 1;
                else if (a == 9) a = 2;
                if (b == 0) b = 2;
                else if (b == 1) b = 7;
                else if (b == 2) b = 2;
                else if (b == 3) b = 3;
                else if (b == 4) b = 3;
                else if (b == 5) b = 4;
                else if (b == 6) b = 2;
                else if (b == 7) b = 5;
                else if (b == 8) b = 1;
                else if (b == 9) b = 2;
                Console.WriteLine(a*b);
            }
        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
            if (n2 == 2 | n2 == 0 | n2 == 6 | n2 == 9) count1 = count1 + 2;
            else
                if (n2 == 3 | n2 == 4) count1 = count1 + 3;
                else
                    if (n2 == 5) count1 = count1 + 4;
                    else
                        if (n2 == 1) count1 = count1 + 7;
                        else
                            if (n2 == 8) count1 = count1 + 1; else if (n2 == 7) count1 = count1 + 5;
            if (n1 == 2 | n1 == 0 | n1 == 6 | n1 == 9) count2 = count2 + 2;
            else
                if (n1 == 3 | n1 == 4) count2 = count2 + 3;
                else
                    if (n1 == 5) count2 = count2 + 4;
                    else
                        if (n1 == 1) count2 = count2 + 7;
                        else
                            if (n1 == 8) count2 = count2 + 1; else
                                if (n1 == 7) count2 = count2 + 5;
            Console.WriteLine(count1 * count2);
            Console.ReadLine();

        }
    }
}

using System;

namespace R_A_282
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = int.Parse(Console.ReadLine());
            int a = Vib(n / 10), b = Vib(n % 10);
            Console.WriteLine(a * b);
        }

        public static int Vib(int a)
        {
            switch (a)
            {
                case 0:
                    return 2;
                    break;
                case 1:
                    return 7;
                    break;
                case 2:
                    return 2;
                    break;
                case 3:
                    return 3;
                    break;
                case 4:
                    return 3;
                    break;
                case 5:
                    return 4;
                    break;
                case 6:
                    return 2;
                    break;
                case 7:
                    return 5;
                    break;
                case 8:
                    return 1;
                    break;
                case 9:
                    return 2;
                    break;
                default:
                    return 0;
                    break;
            }
        }
    }
}

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

namespace Digital_Counter
{
    class Program
    {
        static void Main(string[] args)
        {
            IO io = new IO();
            int[] arr_data = new int[] { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            string arr_Inputs = Console.ReadLine();
            int firstDigit = Convert.ToInt32(arr_Inputs[0].ToString());
            int secondDigit = Convert.ToInt32(arr_Inputs[1].ToString());
            io.PutStr(arr_data[firstDigit] * arr_data[secondDigit]);
            io.ReadNum();
        }
    }
    class IO
    {
        private static Queue<string> currentLineTokens = new Queue<string>();
        private static string[] ReadAndSplitLine()
        {
            return Console.ReadLine().Split(new[] { ' ', '\t' }, StringSplitOptions.RemoveEmptyEntries);
        }
        public int ReadNextInt()
        {
            return int.Parse(ReadToken());
        }
        public int ReadNum()
        {
            return Convert.ToInt32(Console.ReadLine());
        }
        public long ReadLong()
        {
            return Convert.ToInt64(Console.ReadLine());
        }
        public string ReadStr()
        {
            return Console.ReadLine();
        }
        public string[] ReadStrArr()
        {
            return Console.ReadLine().Split(' ');
        }
        public int[] ReadIntArr()
        {
            return Array.ConvertAll<string, int>(Console.ReadLine().Split(' '), s => int.Parse(s));
        }
        public void PutStr(string str)
        {
            Console.WriteLine(str);
        }
        public void PutStr(int str)
        {
            Console.WriteLine(str);
        }
        public void PutStr(long str)
        {
            Console.WriteLine(str);
        }

        public static string ReadToken()
        {
            while (currentLineTokens.Count == 0)
                currentLineTokens = new Queue<string>(ReadAndSplitLine());
            return currentLineTokens.Dequeue();
        }
    }
}

using System;

namespace ConsoleApplication1
{
    public static class Class1
    {
        static void Main(string[] args)
        {
            var data = new[] { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            var number = Console.ReadLine();
            var firstDigit = int.Parse(number[0].ToString());
            var secondDigit = int.Parse(number[1].ToString());
            Console.WriteLine(data[firstDigit]*data[secondDigit]);
        }
    }
}

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

namespace ConsoleA
{
    class Program
    {
        static void Main ( string[] args )
        {
            int a = 0, b = 0, p = 0;
            string str = Console.ReadLine ( );
            for ( int i = 0; i < str.Length; i++ )
            {
                switch (str[i])
                {
                    case '0':
                        p = 2;   // 0 8
                        break;
                    case '1':
                        p = 7;   // 1 0 3 4 7 8 9
                        break;
                    case '2':
                        p = 2;   // 2 8
                        break;
                    case '3':
                        p = 3;  // 3 8 9
                        break;
                    case '4':
                        p = 3;   // 4 8 9
                        break;
                    case '5':
                        p = 4;  //5 6 8 9
                        break;
                    case '6':
                        p = 2;   //6 8
                        break;
                    case '7':
                        p = 5;   //7 0 3 8 9
                        break;
                    case '8':
                        p = 1;  //8
                        break;
                    case '9':
                        p = 2;  //9 8
                        break;
                }
                if ( i == 0 )
                    a = p;
                else b = p;
            }
            Console.WriteLine ( ( a * b ).ToString ( ) );
        }
    }
}

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

namespace Application
{
    class Program
    {
        static void Main(string[] args)
        {
            string lev = Console.ReadLine();
            int n = 0;
            char l ;
            int level = 1;
            int count1 = 1;
            int count2 = 1;

            l = lev[0];
            level = int.Parse(l.ToString());
            count1 = Con(level, count1);
            l = lev[1];
            level = int.Parse(l.ToString());
            count2 = Con(level, count2);
            n = count1 * count2;

            Console.Write(n);
            lev = Console.ReadLine();

        }

        private static int Con(int level10, int count1)
        {
            switch (level10)
            {
                case 0:
                    count1 = 2;
                    break;
                case 1:
                    count1 = 7;
                    break;
                case 2:
                    count1 = 2;
                    break;
                case 3:
                    count1 = 3;
                    break;
                case 4:
                    count1 = 3;
                    break;
                case 5:
                    count1 = 4;
                    break;
                case 6:
                    count1 = 2;
                    break;
                case 7:
                    count1 = 5;
                    break;
                case 8:
                    count1 = 1;
                    break;
                case 9:
                    count1 = 2;
                    break;
                default:
                    Console.WriteLine("Default case");
                    break;
            }
            return count1;
        }

    }
}

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

namespace Application
{
    class Program
    {
        static void Main(string[] args)
        {
            string lev = Console.ReadLine();
            int n = 0;
            char l ;
            int level = 1;
            int count1 = 1;
            int count2 = 1;

            l = lev[0];
            level = int.Parse(l.ToString());
            count1 = Con(level, count1);
            l = lev[1];
            level = int.Parse(l.ToString());
            count2 = Con(level, count2);
            n = count1 * count2;

            Console.Write(n);
            lev = Console.ReadLine();

        }

        private static int Con(int level, int count1)
        {
            switch (level)
            {
                case 0:
                    count1 = 2;
                    break;
                case 1:
                    count1 = 7;
                    break;
                case 2:
                    count1 = 2;
                    break;
                case 3:
                    count1 = 3;
                    break;
                case 4:
                    count1 = 3;
                    break;
                case 5:
                    count1 = 4;
                    break;
                case 6:
                    count1 = 2;
                    break;
                case 7:
                    count1 = 5;
                    break;
                case 8:
                    count1 = 1;
                    break;
                case 9:
                    count1 = 2;
                    break;
                default:
                    Console.WriteLine("Default case");
                    break;
            }
            return count1;
        }

    }
}

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

namespace Digital_Counter
{
    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)
        {
            var good = new[] {2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
            string s = reader.ReadLine();

            writer.WriteLine(good[s[0] - '0']*good[s[1] - '0']);
            writer.Flush();
        }
    }
}

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

namespace A
{
    class Program
    {
        static Dictionary<char, int> _le = new Dictionary<char, int>() { {'0', 2}, {'1', 7}, {'2', 2}, {'3', 3}, {'4', 3}, {'5', 4}, {'6', 2}, {'7', 5}, {'8', 1}, {'9', 2} };

        static void Main(string[] args)
        {
            //Console.SetIn(File.OpenText("in.txt"));
            var n = Console.ReadLine();
            var res = _le[n[0]] * _le[n[1]];
            Console.WriteLine(res);

        }
    }
}

using System;
using System.Text;
public class Test
{
    public static void Main()
    {
        // your code goes here
        string str = Console.ReadLine().Trim();
        int[] arr = new int[]{2,7,2,3,3,4,2,5,1,2};
        if(str.Length > 1){
            int a1 = (int)str[0] - (int)'0';
            int b1 = (int)str[1] - (int)'0';
            Console.WriteLine(arr[a1] * arr[b1]);
        }else{
            int a1 = (int)str[0] - (int)'0';
            //int b1 = (int)str[1] - (int)'0';
            Console.WriteLine(arr[a1]);
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Text.RegularExpressions;
using System.IO;
using System.Numerics;
using System.Globalization;
using System.Threading;

namespace probleme {
    class Program {
        static void Main(string[] args) {
            //Console.SetIn(new StreamReader("file.txt"));
            int n = int.Parse(Console.ReadLine());
            int[] v = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            int m = n % 10;
            n /= 10;
            Console.Write(v[n] * v[m]);
            //Console.ReadKey();
        }
    }
}

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

namespace ConsoleApplication6
{
    class Program
    {
        static void Main(string[] args)
        {
            int m = Convert.ToInt32(Console.ReadLine());
            int b = m % 10;
            int a = (m - b) / 10;
            int[] ar = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            Console.WriteLine(ar[a] *ar[b]);
        }
    }
}

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

namespace ConsoleApplication2
{
    class Program
    {
        static int kachestvo(int n)
        {
            if (n == 0 || n==2 || n==9) return 2;
            else
                if (n == 1) return 7;
                else
                        if (n == 3 || n == 4 || n == 6) return 3;
                        else
                            if (n == 5) return 4;
                            else
                                if (n == 7) return 5;
                                else return 1;

        }
        static void Main(string[] args)
        {
            int n = Convert.ToInt32(Console.ReadLine());
            Console.WriteLine(kachestvo(n / 10) * kachestvo(n % 10));

        }
    }
}

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

namespace Digital_Counter
{
    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)
        {
            var good = new[] {2, 7, 2, 3, 3, 3, 2, 5, 1, 2};
            string s = reader.ReadLine();

            writer.WriteLine(good[s[0] - '0']*good[s[1] - '0']);
            writer.Flush();
        }
    }
}

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

namespace A
{
    class Program
    {
        static void Main(string[] args)
        {
            string s;
            s = Console.ReadLine();
            char d, f;
            d = s[0];
            f = s[1];
            int a = (int)Char.GetNumericValue(d);
            int b = (int)Char.GetNumericValue(f);
            if (a == b)
            {
                if (a == 0) a = 2;
                else if (a == 1) a = 6;
                else if (a == 2) a = 2;
                else if (a == 3) a = 3;
                else if (a == 4) a = 3;
                else if (a == 5) a = 4;
                else if (a == 6) a = 2;
                else if (a == 7) a = 5;
                else if (a == 8) a = 1;
                else if (a == 9) a = 2;
                Console.WriteLine(a*a);
            }
            else
            {
                if (a == 0) a = 2;
                else if (a == 1) a = 7;
                else if (a == 2) a = 2;
                else if (a == 3) a = 3;
                else if (a == 4) a = 3;
                else if (a == 5) a = 4;
                else if (a == 6) a = 2;
                else if (a == 7) a = 5;
                else if (a == 8) a = 1;
                else if (a == 9) a = 2;
                if (b == 0) b = 2;
                else if (b == 1) b = 7;
                else if (b == 2) b = 2;
                else if (b == 3) b = 3;
                else if (b == 4) b = 3;
                else if (b == 5) b = 4;
                else if (b == 6) b = 2;
                else if (b == 7) b = 5;
                else if (b == 8) b = 1;
                else if (b == 9) b = 2;
                Console.WriteLine(a*b);
            }

        }
    }
}

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

namespace A
{
    class Program
    {
        static Dictionary<char, int> _le = new Dictionary<char, int>() { {'0', 2}, {'1', 7}, {'2', 2}, {'3', 3}, {'4', 3}, {'5', 3}, {'6', 2}, {'7', 5}, {'8', 1}, {'9', 2} };

        static void Main(string[] args)
        {
            //Console.SetIn(File.OpenText("in.txt"));
            var n = Console.ReadLine();
            var res = _le[n[0]] * _le[n[1]];
            Console.WriteLine(res);

        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Text.RegularExpressions;
using System.IO;
using System.Numerics;
using System.Globalization;
using System.Threading;

namespace probleme {
    class Program {
        static void Main(string[] args) {
            //Console.SetIn(new StreamReader("file.txt"));
            int n = int.Parse(Console.ReadLine());
            int[] v = { 2, 7, 2, 3, 3, 4, 2, 4, 1, 2 };
            int m = n % 10;
            n /= 10;
            Console.Write(v[n] * v[m]);
            //Console.ReadKey();
        }
    }
}

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

namespace prA {

    class Program {
#if ONLINE_JUDGE
        private static readonly StreamReader reader = new StreamReader(Console.OpenStandardInput(1024 * 10), System.Text.Encoding.ASCII, false, 1024 * 10);
        private static readonly StreamWriter writer = new StreamWriter(Console.OpenStandardOutput(1024 * 10), System.Text.Encoding.ASCII, 1024 * 10);
#else
        private static readonly StreamWriter writer = new StreamWriter("output");
        private static readonly StreamReader reader = new StreamReader("input");
#endif
        static void Main(string[] args) {
            int[] d = {2, 1 + 1 + 1 + 1 + 1 + 1, 1 + 1, 1 + 1 + 1, 1 + 1 + 1, 1 + 1 + 1 + 1, 1 + 1, 1 + 1 + 1 + 1 + 1, 1, 1 + 1};
            string s = reader.ReadLine();
            int ans = d[s[0] - '0'] * d[s[1] - '0'];
            writer.Write(ans);
            writer.Flush();
#if !ONLINE_JUDGE
            writer.Close();
#endif
        }
        private static int Next() {
            int c;
            int res = 0;
            do {
                c = reader.Read();
                if(c == -1)
                    return res;
            } while(c != '-' && (c < '0' || c > '9'));
            int sign = 1;
            if(c == '-') {
                sign = -1;
                c = reader.Read();
            }
            res = c - '0';
            while(true) {
                c = reader.Read();
                if(c < '0' || c > '9')
                    return res * sign;
                res *= 10;
                res += c - '0';
            }
        }
    }
}

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

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int f = Convert.ToInt32(Console.ReadLine());
            int f1 = f / 10;
            int f2 = f % 10;
            int[] p = { 2, 6, 3, 3, 3, 4, 2, 5, 1, 2 };

            Console.WriteLine(p[f1] * p[f2]);
            Console.ReadLine();
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main()
        {
            //int t = int.Parse(Console.ReadLine());
            int a = Console.Read() - '0',
                b = Console.Read() - '0';

            var transform = new List<int>
            {
                2,
                7,
                2,
                3,
                3,
                4,
                3,
                5,
                1,
                2
            };

            Console.WriteLine(transform[a] * transform[b]);
        }
    }

}

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

namespace ConsoleApplication10
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Convert.ToInt32(Console.ReadLine());
            int b = n % 10;
            int a = (n - b) % 10;
            int[] s = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2 };
            Console.WriteLine(s[a]*s[b]);
            Console.ReadLine();

        }
    }
}

using System;
class Program
{
    static void Main()
    {
        var ar = new int[] { 126, 48, 109, 121, 51, 91, 95, 112, 127, 123 };
        var ans = 0;
        var d = int.Parse(Console.ReadLine());
        var b = ar[d % 10];
        d /= 10;
        var a = ar[d % 10];
        foreach (var item in ar)
        {
            if ((a & item) >= a )
            {
                ans++;
            }
        }
        foreach (var item in ar)
        {
            if ((b & item) >= b)
            {
                ans++;
            }
        }
        Console.WriteLine(ans);
    }
}

using System;
class Program
{
    static void Main()
    {
        var ar = new int[] { 126, 48, 109, 121, 51, 91, 95, 112, 127, 123 };
        var ans = 0;
        var d = int.Parse(Console.ReadLine());
        var b = ar[d % 10];
        d /= 10;
        var a = ar[d % 10];
        foreach (var item in ar)
        {
            if ((a & item) >= a || (b & item) >= b)
            {
                ans++;
            }
        }
        Console.WriteLine(ans);
    }
}

using System;
namespace CodeForces{
    class Contest {
        static void Main(string [] Args) {
            string s = Console.ReadLine();
            int[] dig = { 2, 6, 2, 3, 3, 9, 2, 5, 1, 2};
            int a = s[0]-'0';
            int b = s[1]-'0';
            Console.Write(string.Format("{0}", dig[a] * dig[b]));
        }
    }
}

using System;
namespace CodeForces{
    class Contest {
        static void Main(string [] Args) {
            string s = Console.ReadLine();
            int[] dig = { 2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
            Console.Write(dig[s[0]-'0']*dig[s[0]-'0']);
        }
    }
}

using System;
namespace CodeForces{
    class Contest {
        static void Main(string [] Args) {
            string s = Console.ReadLine();
            int[] dig = { 2, 7, 2, 3, 3, 9, 2, 5, 1, 2};
            int a = s[0]-'0';
            int b = s[1]-'0';
            Console.Write(string.Format("{0}", dig[a] * dig[b]));
        }
    }
}

using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Security.Policy;

namespace ConsoleApplication3
{
    internal class NumberIndicator
    {
        public static List<byte[]> Numbers = new List<byte[]>
        {
            new byte[] {1, 1, 1, 1, 1, 1, 0},
            new byte[] {0, 0, 1, 1, 0, 0, 0},
            new byte[] {0, 1, 1, 0, 1, 1, 1},
            new byte[] {0, 1, 1, 1, 1, 0, 1},
            new byte[] {1, 0, 1, 1, 0, 0, 1},
            new byte[] {0, 1, 0, 1, 1, 0, 1},
            new byte[] {1, 1, 0, 1, 1, 1, 1},
            new byte[] {0, 1, 1, 1, 0, 0, 0},
            new byte[] {1, 1, 1, 1, 1, 1, 1},
            new byte[] {1, 1, 1, 1, 1, 0, 1},
        };

        public static int FindGoodNumbers(int first, int second)
        {
            var firstBinaryNum = Numbers.ElementAt(first);
            var secondBinaryNum = Numbers.ElementAt(second);

            var firstResult = 0;
            var secondResult = 0;
            foreach (var number in Numbers)
            {
                var addFirst = true;
                var addSecond = true;
                for (var i = 0; i < number.Length; i++)
                {
                    if (firstBinaryNum[i] == 1 && number[i] != 1)
                    {
                        addFirst = false;
                    }
                    if (secondBinaryNum[i] == 1 && number[i] != 1)
                    {
                        addSecond = false;
                    }
                }
                if (addFirst)
                {
                    firstResult++;
                }
                if (addSecond)
                {
                    secondResult++;
                }
            }
            return firstResult*secondResult;
        }

        private static void Main(string[] args)
        {
            var stringNumber = Console.ReadLine();
            if (stringNumber == null) return;
            var result = FindGoodNumbers((int) Char.GetNumericValue(stringNumber[0]),
                (int) Char.GetNumericValue(stringNumber[1]));
            Console.WriteLine(result);
        }
    }
}

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

namespace _13._12
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] a = { 2, 7, 2, 3, 3, 3, 2, 5, 1, 2 };
            string s = Console.ReadLine();
            if (s.Length == 2 && s[0] >= '0' && s[0] <= '9' && s[1] >= '0' && s[1] <= '9')
            {
                int a1 = Convert.ToInt32(s[0].ToString());
                int a2 = Convert.ToInt32(s[1].ToString());
                Console.WriteLine(a[a1] * a[a2]);
            }
        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
                if (n2 == 0 | n2 == 6 | n2 == 9) count1 = count1 + 2; else
                    if(n2 == 2 | n2 == 3 | n2 == 5) count1 = count1 + 3; else
                        if(n2==4) count1 = count1 + 4; else
                            if(n2==7) count1 = count1 + 5; else
                                if (n2 == 1) count1 = count1 + 6;
                if (n1 == 0 | n1 == 6 | n1 == 9) count2 = count2 + 2;
                else
                    if (n1 == 2 | n1 == 3 | n1 == 5) count2 = count2 + 3;
                    else
                        if (n1 == 4) count2 = count2 + 4;
                        else
                            if (n1 == 7) count2 = count2 + 5;
                            else
                                if (n1 == 1) count2 = count2 + 6;
            if(count1!=0&count2!=0)Console.WriteLine(count1*count2);
            else Console.WriteLine(count1 + count2);
            //Console.ReadLine();

        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
            if (n2 == 0 | n2 == 6 | n2 == 9) count1 = count1 + 2;
            else
                if (n2 == 2 | n2 == 3 | n2 == 5) count1 = count1 + 3;
                else
                    if (n2 == 4) count1 = count1 + 4;
                    else
                        if (n2 == 7) count1 = count1 + 5;
                        else
                            if (n2 == 1) count1 = count1 + 6; else count1 = 1;
                if (n1 == 0 | n1 == 6 | n1 == 9) count2 = count2 + 2;
                else
                    if (n1 == 2 | n1 == 3 | n1 == 5) count2 = count2 + 3;
                    else
                        if (n1 == 4) count2 = count2 + 4;
                        else
                            if (n1 == 7) count2 = count2 + 5;
                            else
                                if (n1 == 1) count2 = count2 + 6; else count2 = 1;
            if(count1!=0&count2!=0) Console.WriteLine(count1*count2);
            else Console.WriteLine(count1 + count2);
           // Console.ReadLine();

        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
            if (n2 == 2 | n2 == 0 | n2 == 6 | n2 == 9) count1 = count1 + 2;
            else
                if (n2 == 3 | n2 == 4) count1 = count1 + 3;
                else
                    if (n2 == 5) count1 = count1 + 4;
                    else
                        if (n2 == 1) count1 = count1 + 7;
                        else
                            if (n2 == 8) count1 = count1 + 1; else if (n1 == 7) count1 = count1 + 5; else count1 = 1;
            if (n1 == 2 | n1 == 0 | n1 == 6 | n1 == 9) count2 = count2 + 2;
            else
                if (n1 == 3 | n1 == 4) count2 = count2 + 3;
                else
                    if (n1 == 5) count2 = count2 + 4;
                    else
                        if (n1 == 1) count2 = count2 + 7;
                        else
                            if (n1 == 8) count2 = count2 + 1; else
                                if (n1 == 7) count2 = count2 + 5; else count2 = 1;
            Console.WriteLine(count1 * count2);
            Console.ReadLine();

        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
            if (n2 == 2 | n2 == 0 | n2 == 9) count1 = count1 + 2;
            else
                if (n2 == 3 | n2 == 4) count1 = count1 + 3;
                else
                    if (n2 == 5) count1 = count1 + 4;
                    else
                        if (n2 == 1) count1 = count1 + 7;
                        else
                            if (n2 == 8) count1 = count1 + 1; else count1 = 1;
            if (n1 == 2 | n1 == 0 | n1 == 9) count2 = count2 + 2;
            else
                if (n1 == 3 | n1 == 4) count2 = count2 + 3;
                else
                    if (n1 == 5) count2 = count2 + 4;
                    else
                        if (n1 == 1) count2 = count2 + 7;
                        else
                            if (n1 == 8) count2 = count2 + 1; else count2 = 1;
            Console.WriteLine(count1 * count2);

        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
            if (n2 == 2 | n2 == 0 | n2 == 6 | n2 == 9) count1 = count1 + 2;
            else
                if ( n2 == 3 | n2 == 5) count1 = count1 + 3;
                else
                    if (n2 == 4) count1 = count1 + 3;
                    else
                        if (n2 == 7) count1 = count1 + 7;
                        else
                            if (n2 == 1) count1 = count1 + 6; else count1 = 1;
            if (n1 == 2 | n1 == 0 | n1 == 6 | n1 == 9) count2 = count2 + 2;
                else
                    if ( n1 == 3 | n1 == 5) count2 = count2 + 3;
                    else
                        if (n1 == 4) count2 = count2 + 3;
                        else
                            if (n1 == 7) count2 = count2 + 5;
                            else
                                if (n1 == 1) count2 = count2 + 7; else count2 = 1;
            if(count1!=0&count2!=0) Console.WriteLine(count1*count2);
            else Console.WriteLine(count1 + count2);
           //Console.ReadLine();

        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
            if (n2 == 2 | n2 == 0 | n2 == 6 | n2 == 9) count1 = count1 + 2;
            else
                if (n2 == 3 | n2 == 4) count1 = count1 + 3;
                else
                    if (n2 == 5) count1 = count1 + 4;
                    else
                        if (n2 == 1) count1 = count1 + 7;
                        else
                            if (n2 == 8) count1 = count1 + 1; else if (n1 == 7) count2 = count2 + 5; else count1 = 1;
            if (n1 == 2 | n1 == 0 | n1 == 6 | n1 == 9) count2 = count2 + 2;
            else
                if (n1 == 3 | n1 == 4) count2 = count2 + 3;
                else
                    if (n1 == 5) count2 = count2 + 4;
                    else
                        if (n1 == 1) count2 = count2 + 7;
                        else
                            if (n1 == 8) count2 = count2 + 1; else
                                if (n1 == 7) count2 = count2 + 5; else count2 = 1;
            Console.WriteLine(count1 * count2);
            Console.ReadLine();

        }
    }
}

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

namespace ConsoleApplication56
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Int32.Parse(Console.ReadLine());
            int n1 = n / 10;
            int n2 = n % 10;
            int count1 = 0;
            int count2 = 0;
            if (n2 == 2 | n2 == 0 | n2 == 9) count1 = count1 + 2;
            else
                if (n2 == 3 | n2 == 4) count1 = count1 + 3;
                else
                    if (n2 == 5) count1 = count1 + 4;
                    else
                        if (n2 == 1) count1 = count1 + 7;
                        else
                            if (n2 == 8) count1 = count1 + 1; else if (n1 == 7) count2 = count2 + 5; else count1 = 1;
            if (n1 == 2 | n1 == 0 | n1 == 9) count2 = count2 + 2;
            else
                if (n1 == 3 | n1 == 4) count2 = count2 + 3;
                else
                    if (n1 == 5) count2 = count2 + 4;
                    else
                        if (n1 == 1) count2 = count2 + 7;
                        else
                            if (n1 == 8) count2 = count2 + 1; else
                                if (n1 == 7) count2 = count2 + 5; else count2 = 1;
            Console.WriteLine(count1 * count2);
            Console.ReadLine();

        }
    }
}