<div class="gmail_quote">On Mon, Dec 10, 2012 at 5:33 AM, Doug McIlroy <span dir="ltr">&lt;<a href="mailto:doug@cs.dartmouth.edu" target="_blank">doug@cs.dartmouth.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
&gt; &gt;   Matlab exploits them heavily (though represented as doubles).<br><div class="im">
<br>
&gt; Not sure what you are referring to<br>
<br>
</div>I had in mind Matlab&#39;s frequent use of a Boolean array as<br>
a characteristic function describing some property of the<br>
elements of another array.  Such arrays are used to control<br>
other array operations. In this usage, the characteristic<br>
array may be optimized out of existense, but it fosters<br>
higher-level thinking and concise code.<br clear="all"></blockquote></div><br>In which case it goes back to APL&#39;s compress operator ie 1960.<br><a href="http://www.aplusdev.org/APlusRefV2_8.html#HEADING179">http://www.aplusdev.org/APlusRefV2_8.html#HEADING179</a><br>
<br>Heres a session that demonstrates<br><br>     A+<br>     Copyright (c) 1990-2008 Morgan Stanley.  All rights reserved.<br>     This version is Release 4.22<br>     a ← 1 2 3 4 5<br>     b ← 1 0 1 1 0<br>     b/a<br> 1 3 4<br>
     b ← 1 0 2 1 0<br>     b/a<br> 1 3 3 4<br><br><br><br>-- <br><a href="http://www.the-magus.in" target="_blank">http://www.the-magus.in</a><br><a href="http://blog.languager.org" target="_blank">http://blog.languager.org</a><br>
<br><br>