Yes, but that's a wrong and unfair way to define and apply laws.
> humans are imperfect
Smart contracts and "code is the law" mantra don't contradict this. You're imperfect and you commit a mistake, you lose. You find a mistake in someone else's code, you win.
This is much better than the current legal system where we are all collectively forced to adapt to, or even pay for, someone else's mistakes.