educoder/app/helpers/challenges_helper.rb

15 lines
204 B
Ruby

# encoding: utf-8
module ChallengesHelper
def difficulty_type difficulty
case difficulty
when 1
"简单"
when 2
"中等"
when 3
"复杂"
end
end
end