Following is one very popular image which has been used to represent time and again for representing code smells. I…