bug-apl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-apl] Help with APL expression


From: Elias Mårtenson
Subject: [Bug-apl] Help with APL expression
Date: Wed, 5 Jul 2017 17:43:34 +0800

I have a list of strings, and a corresponding set of categorisations:

      strings ← 'foo' 'bar' 'abc' 'def' 'ghi' 'jkl'
      categories ← 1 1 0 2 1 0

I now need to group these strings according to category. In other words, when applying operation X, I need the following output:

      categories X strings
┏→━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃┏→━━━━━━━━━━┓ ┏→━━━━━━━━━━━━━━━━┓ ┏→━━━━┓┃
┃┃"abc" "jkl"┃ ┃"foo" "bar" "hgi"┃ ┃"def"┃┃
┃┗∊━━━━━━━━━━┛ ┗∊━━━━━━━━━━━━━━━━┛ ┗∊━━━━┛┃
┗∊∊━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛

What is the best way to solve this?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]