Comma quibbling: Difference between revisions
Content deleted Content added
→{{header|Visual Basic .NET}}: Added VB.NET |
Drkameleon (talk | contribs) No edit summary |
||
Line 559:
{Jack and Jill}
{Loner}</pre>
=={{header|Arturo}}==
<lang arturo>quibble [seq]{
if $(size seq)=0 { return "{}" } {
if $(size seq)=1 { return "{`seq.0`}" } {
return "{" + $(join $(slice seq 0 $(size seq)-1) ", ") + " and " + $(last seq) + "}"
}
}
}
loop #(#() #("ABC") #("ABC" "DEF") #("ABC" "DEF" "G" "H")) {
print $(quibble &)
}</lang>
{{out}}
<pre>{}
{ABC}
{ABC and DEF}
{ABC, DEF, G and H}</pre>
=={{header|Astro}}==
|