sort a golang map by key or value by given less function, output is a sorted slice see detailed useage test dir