Add lab 2 code

Need to finish the threshold !!