using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace yukicoderTest { class Program { static void Main(string[] args) { string input = Console.ReadLine(); string[] LK = input.Split(' '); int L = int.Parse(LK[0]); int K = int.Parse(LK[1]); int cm = 0; while(L>K*2) { L = L - K * 2; cm = cm + K; } Console.WriteLine(cm); } } }