I agree with Michael with the following addition. The critical fact is that the notice period had not expired and therefore the contract of employment had not yet terminated when A’s duties were changed to that of “odd jobs”(see Mthimkhulu v Standard Bank of South Africa  1 BLLR 86 (LC) which held that the contract of employment in a resignation situation terminates when the notice period expires). Therefore, unless (as Ivan points out) there is another fair reason for retrenching A instead of B, LIFO must apply.
However, I think (but am not totally sure about this) the position might be different if the notice period had expired AND THEN the employer agreed to keep A on with a change in job requirements. Surely B could argue that A was re-employed in terms of a new, albeit tacit or verbal contract, and because A’s (and not B’s) new position had become redundant, A’s position could be terminated for operational requirements as he would have been employed in terms of a new contract and would therefore be considered to be LAST IN.