Booleans in Dyalog APL
- Booleans are integers which are zero or one
- Many APLs including Dyalog store booleans as efficiently as possible, packing eight in each byte
- This is difficult to implement and only offers benefits for arrays, so nearly all other languages use an entire byte per boolean
- However, it gives Dyalog APL a huge boost in performance, especially on modern machines where the limiting factor is often memory bandwidth (the time required to move data around)
- A well-implemented primitive is typically eight times faster on booleans than on 1-byte integers