Skip to content

jsl/utils

Package name: jsl/utils

Summary

General Definitions

Function Description
unpack De-structure a KeyValue into two components

Definitions

General Definitions

unpack

De-structure a KeyValue into two components

public defn unpack (kp:KeyValue) -> [?, ?]

  • Returns [?, ?]
val kp = "apple" => 2
val [name, cnt] = unpack(kp)
println("Name: %_ Cnt: %_" % [name, cnt])

; Prints:
; Name: apple Cnt: 2