using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace YukiCoder { class Program { static void Main(string[] args) { var va = Console.ReadLine().Split().Select(int.Parse).ToArray(); int n1 = va[0]; int n5 = va[1]; bool[] pn = new bool[n5 * 5 + n1 + 1]; for (int i = 0; i <= n1; i++) { for (int j = 0; j <= n5; j++) { pn[j * 5 + i] = true; } } for(int i=1; i