Task

Create an enumeration of constants with and without explicit values.




IN: scratchpad { "sun" "mon" "tue" "wed" "thur" "fri" "sat" } <enum>
 
--- Data stack:
T{ enum f ~array~ }
IN: scratchpad [ 1 swap at ] [ keys ] bi
 
--- Data stack:
"mon"
{ 0 1 2 3 4 5 6 }