The criminal to the judge: I have no free will, so you can't put me in prison.
The judge: I have no free will, so I sentence you to prison.
If there are no free will, most of us are programmed to put some humans in prison, so there is no problem even if there is no free will.
Now the core argument for free will and programming is not that we have metaphysical free will, but that some humans can self program, they can change their behavior due to have the ability to do mentalizing and meta-cognition. That is how we hold each other responsible in effect. You should know what you have done is wrong, unless you are insane. If you are not insane or otherwise cognitive incapable, then you should now what you have done, is wrong and shouldn't have do it.
In effect we know that humans can change behavior, thus we hold them responsible for not do something else than the crime