How does the write off being more valuable than selling for parts work?
If you sold the business for parts, for $50m you end up with $150 in profit (technically could be less if you took an impairment (like a writeoff but not for the full amount since you clearly recouped some value). You pay taxes on your profits and end up net negative against the scenario where you just shut it down.
This is overly simplistic but the gist of it is directionally correct.