Files
2026-01-15 14:01:21 +09:00

14 lines
193 B
Ruby
Executable File

#!/usr/bin/ruby
# -*- coding: utf-8 -*-
=begin
문자열을 받아 길이를 반환하는 메서드
=end
def len(s)
s.length
end
print "?"
s = gets.chomp
puts "#{s}의 길이는 #{len(s)}"