Testing and learning code