using System; using System.Collections; using System.Collections.Generic; using System.Collections.Specialized; using System.Text; using System.Text.RegularExpressions; using System.Linq; class Magatro { static void Main() { long ans = 1; for(int i = 1; i <= 26; i++) { switch (i) { case 4: case 5: case 8: case 18: case 23: ans *= int.Parse(Console.ReadLine()); break; case 15: int o = int.Parse(Console.ReadLine()); ans *= ((o / 2) * ((o + 1) / 2)); break; case 12: int l = int.Parse(Console.ReadLine()); if (l < 3) { ans = 0; } else { ans *= lcnt(l); } break; default: Console.ReadLine(); break; } } Console.WriteLine(ans); } static int kaijou(int n) { if (n == 1) { return 1; } return n + kaijou(n - 1); } static int lcnt(int l) { int max = 0; for(int i = 2; i < l; i++) { int r = l - i; int cnt = ((i - 1) * i / 2) * r; max = Math.Max(max, cnt); } return max; } }