added initial version of code