implement keys_array and values_array functions
speed commit