HC-05 sends endless println messages and does not respond

GolamMostafa:
Sometimes, the erratic behaviors are changed, which are called side affects.

That is not helpful for a newbie. You need to point out what behaviour needed to be changed.

If you have not considered whether something needed to be changed and made a conscious effort to change it then you have what I call the scatter-gun approach to debugging which, IMHO, is a complete waste of time and is a very poor example to put before a newbie.

...R