Let number of first kind of cake is \(\mathrm{X}\) and another kind of cake is \(\mathrm{Y}\).
So, total flour required \(=200 \mathrm{X}+100 \mathrm{Y} \mathrm{g}\)
And total fat required \(=25 \mathrm{X}+50 \mathrm{Y} \mathrm{g}\)
Since, maximum flour available is \(5 \mathrm{~kg}=5000 \mathrm{~g}\)
\(\therefore 200 \mathrm{X}+100 \mathrm{Y} \leq 5000\)
\(\Rightarrow 2 \mathrm{X}+\mathrm{Y} \leq 50\).....(1)
Also, maximum fat available is \(1 \mathrm{~kg}=1000 \mathrm{~g}\)
\(\therefore 25 \mathrm{X}+50 \mathrm{Y} \leq 1000\)
\(\Rightarrow \mathrm{X}+2 \mathrm{Y} \leq 40\)..........(2)
Since, quantity of cakes can't be negative.
\(\therefore \mathrm{X} \geq 0, \mathrm{Y} \geq 0\).....(3)
We have to maximize number of cakes that can be made.
So, Objective function is \(\mathrm{Z}=\mathrm{X}+\mathrm{Y}\)
After plotting all the constraints given by equation (1), (2) and (3), we got the feasible region as shown in the image.
Corner point \(\mathrm{A}(\mathrm{0}, 20)\)
Value of \(Z=0+20=20\)
Corner point \(\mathrm{B}(20,10)\),
Value of \(Z=20+10=30\)
Corner point \(\mathrm{C}(25,0)\),
Value of \(Z=25+0=25\)

So, maximum cake that can be made is \(30\), where first kind of cake will be \(20\) and second kind of cake will be \(10\).