I sympathise. I have not agreed to tech problems in interviews for years. In my experience I get more job offers for more $ if I refuse to do them rather than answering problems either rightly or wrongly. Either makes no difference. I have even turned offers down because of the stupidity of the interviewers.
Stop doing silly interview questions professionals should be above that.