creat a Debugging method to design the code and easily use
Summary
This pull request aims to improve code readability and maintainability by refactoring debugging statements within methods to use individual debugging methods instead.
changes made
Removed inline debugging statements cout from within methods.
Created individual debugging methods to encapsulate debugging logic.
Replaced debugging statements with calls to the newly created debugging methods.