convert almost all files to cpp