First version of code. Model created and first code