Heroes are attacked in sequence. Two of them can not die at the same time. The sub comes in for the first one to die. It is as simple as that.