I've seen book authors talking about solutions to their book. And the two most talked about reasons are
1. Morale Stuff
2. If they provide their solutions online then the Book will not get adapted by professors.
That’s completely fine. Don’t advertise the books for self-learners or “programmers”.
I would like to see actual books targeted at these demographics that provide solutions and aren’t concerned about being adapted in a classroom.
There is a market for those that graduated university a long time ago and would like to learn math outside of a classroom.
These sort of people don’t want to see solutions because they have to turn their work in for a grade, but because they want to check their work and get feedback. Outside of having to consult with TAs or professors they don’t have access to.