Implement some general functions for List