Compare a list of strings: Difference between revisions
→Add Transd
Thundergnat (talk | contribs) m (syntax highlighting fixup automation) |
|||
Line 3,033:
<syntaxhighlight lang="tcl">tcl::mathop::eq {*}$strings; # All values string-equal
tcl::mathop::< {*}$strings; # All values in strict order</syntaxhighlight>
=={{header|Transd}}==
<syntaxhighlight lang="Scheme">#lang transd
MainModule: {
_start: (λ
(for v in [["aa","ab","ad","ae"],["ab","ab","ab","ab"]] do
(lout :boolalpha v)
(lout (not (any v (λ (ret (neq @it (get v 0)))))))
(lout (not (any Range(in: v 1 -0)
(λ (ret (leq @it (get v (- @idx 1))))))) "\n")
)
)
}</syntaxhighlight>
{{out}}
<pre>
["aa", "ab", "ad", "ae"]
false
true
["ab", "ab", "ab", "ab"]
true
false
</pre>
=={{header|VBA}}==
|