ary = [:a, :b, :c] s = "our array is: "if ary.empty? puts s + " empty"else puts s + ary.join(", ")end
Standard input is empty
our array is: a, b, c
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!