use Array: all; use SimplePrint: all; use SimpleFibre: all; use Math: all; use String:{tochar}; inline bool lessthan(char[+] x, char[+] y, double QUADct) { /* Char item comparator */ /* It oughta also ensure that the arguments shapes match... */ z = with(0*_shape_(x) <= iv < _shape_(x)) fold(|, false, x[iv] < y[iv]); return(z); } inline bool greaterthan(char[+] x, char[+] y, double QUADct) { /* Char item comparator */ /* This definition is sort of flakey - it really compares ravels... */ /* It oughta also ensure that the arguments shapes match... */ z = with(0*_shape_(x) <= iv < _shape_(x)) fold(|, false, x[iv] > y[iv]); return(z); } int main() { s1=tochar("string1"); s2=tochar("String2"); s3=tochar("string3"); z=display (tochar("s1,s2,s3 are:")); z=z+display(s1); z=z+display(s2); z=z+display(s3); z=z+display (tochar("string1 >string2, string1>string3")); z=z+display(toi(greaterthan(s1,s2,0.0))); z=z+display(toi(greaterthan(s1,s3,0.0))); z=z+display (tochar("string1 string1")); z=z+display(toi(greaterthan(s1,s1,0.0))); z=z+display (tochar("string1 s2 next")); qgt = with(. <= i <= .) genarray(_shape_(s1), toi(s1[i]>s2[i])); z=z+display(qgt); return(z); }