Vyxapedia

Element - Þṗ - Split on Truthy Indices

Characters: Þ,


Description

Split a list on truthy indices / Partition a list on truthy items


Overloads

  • lst-lst - Split a on truthy indices in b

Examples

  • ⟨1|2|3|4⟩ ⟨0|1|0|0⟩ Þṗ = ⟨⟨1⟩|⟨2|3|4⟩⟩
  • ⟨1|2|3|4|5|6⟩ ⟨0|1|0|0⟩ Þṗ = ⟨⟨1⟩|⟨2|3|4|5|6⟩⟩
  • ⟨2|3|4|5|6⟩ ⟨1|1|0|1⟩ Þṗ = ⟨⟨⟩|⟨2⟩|⟨3|4⟩|⟨5|6⟩⟩