CHAPTER 4 - Updates on code based on the reviewers comments