I don't know why my yarn is appearing all these problems. I could not uninstall it. Every time I uninstall it and reinstall , it always kind of taking what I deleted previously .How can I avoid all these errors and get a workable yarn?
You can simply run
npm uninstall -g yarn to uninstall the yarn from your dependencies
and then run
npm cache clean --force
to clean the cache and then try