The Correct Option is D
Solution and Explanation
Approach (track the total head-count, which never changes during a transfer): A transfer between shifts does not change the school total, so the total is constant until new students arrive — use that to anchor the numbers.
Step 1: Original total is a multiple of $13+9 = 22$. After transfer the total is a multiple of $19+14 = 33$. The same total must be divisible by both $22$ and $33$, so by $\text{lcm}=66$. The smallest workable total: $13x + 9x = 22x$ equals the post-transfer total $33t$. From $22x = 33t \Rightarrow 2x = 3t$. Taking $x=63$ gives total $1386$ ($=66\times21$), and post-transfer parts $\tfrac{19}{33}(1386)=798$ and $\tfrac{14}{33}(1386)=588$. (Check the 21-shift: $13(63)=819 \to 798$, a drop of $21$. Correct.)
Step 2: Now $N$ new students join in ratio $3:8$, so morning gains $\tfrac{3}{11}N$ and afternoon gains $\tfrac{8}{11}N$. Final ratio $5:4$ means final total $= 1386 + N$ splits as $\tfrac59$ and $\tfrac49$.
Step 3: Morning equation: $798 + \tfrac{3}{11}N = \tfrac{5}{9}(1386 + N)$. Note $\tfrac59(1386) = 770$, so $798 + \tfrac{3}{11}N = 770 + \tfrac59 N \Rightarrow 28 = \left(\tfrac59 - \tfrac{3}{11}\right)N = \tfrac{55-27}{99}N = \tfrac{28}{99}N$.
Step 4: Hence $N = 99$.
Answer: $99$ new students joined.