#!/usr/koeki/bin/ruby # coding: utf-8 def tax(price, ratio) # priceに値段、ratioに税率 をもらう charge = price*ratio charge.to_i end