This is the latest working version of cd, version2