require 'prime' n = gets.to_i dp = Array.new(10001, false) primes = Prime.each(n).to_a 2.upto(n) do |i| sub_p = primes.select { |p| p <= i } sub_p.each do |p| next if i-p <= 1 if dp[i-p] == false dp[i] = true break end end end puts dp[n] ? 'Win' : 'Lose'