start to write some algorithms codes