题目描述
Write your program in Ruby which takes an un-indented Ruby code as string and outputs the indented Ruby code as string.
Input Format
A string which is un-indented Ruby code
Output Format
A string which is indented Ruby code
SAMPLE INPUT
class YabbaDabbaDoo
def foo
if foo == 42
puts 'world hello'
elsif foo == 24
puts 'bk201'
else
puts 'congrats!'
end
end
end
SAMPLE OUTPUT
class YabbaDabbaDoo
def foo
if foo == 42
puts 'world hello'
elsif foo == 24
puts 'bk201'
else
puts 'congrats!'
end
end
end
Explanation
Indentation is of 2 spaces.
输入格式
见题面
输出格式
见题面
样例输入
class YabbaDabbaDoo
def foo
if foo == 42
puts 'world hello'
elsif foo == 24
puts 'bk201'
else
puts 'congrats!'
end
end
end
SAMPLE
样例输出
class YabbaDabbaDoo
def foo
if foo == 42
puts 'world hello'
elsif foo == 24
puts 'bk201'
else
puts 'congrats!'
end
end
end