require 'bigdecimal' class ConsumptionTax attr_reader :d, :p def initialize(d: 0, p: 0) @d, @p = d, p end def datainput begin @d, @p = gets.chomp.split.map { |v| Integer(v) } rescue end end def tax_included_price(price, tax_rate) (price * BigDecimal((1+ tax_rate.to_f / 100).to_s)).floor end def dataoutput puts tax_included_price(@d, @p) end def run datainput dataoutput end end if $0 == __FILE__ ConsumptionTax.new.run end