cons function implement
cons function implement