using System; using System.Collections.Generic; class Program { static void Main() { string[] line = Console.ReadLine().Split(); List rt = new List { "I", "II", "III", "IIII", "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII" }; int newIdx = (rt.IndexOf(line[0]) + int.Parse(line[1])) % 12; if (newIdx < 0) newIdx += 12; Console.WriteLine(rt[newIdx]); } }