RosettaCodeData/Task/String-comparison/Sidef/string-comparison.sidef

6 lines
184 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
var methods = %w(== != > >= < <= <=>)
for s1, s2 in [<YUP YUP>,<YUP Yup>,<bot bat>,<aaa zz>] {
methods.each{|m| "%s %s %s\t%s\n".printf(s1, m, s2, s1.(m)(s2))}
print "\n"
}