Can you find the glaring flaw?? Then please discuss the ramifications of the error...
The first law of thermodynamics may be stated in several ways :
The increase in internal energy of a closed system is equal to total of the energy added to the system. In particular, if the energy entering the system is supplied as heat and if energy leaves the system as work, the heat is accounted for as positive and the work as negative.
{\textstyle \Delta U_{\rm {system}}=Q-W} {\textstyle \Delta U_{\rm {system}}=Q-W}
In the case of a thermodynamic cycle of a closed system, which returns to its original state, the heat Qin supplied to the system in one stage of the cycle, minus the heat Qout removed from it in another stage of the cycle, plus the work added to the system Win equals the work that leaves the system Wout.
{\displaystyle \Delta U_{\rm {system\,(full\,cycle)}}=0} {\displaystyle \Delta U_{\rm {system\,(full\,cycle)}}=0}
hence, for a full cycle,
{\displaystyle Q=Q_{\rm {in}}-Q_{\rm {out}}+W_{\rm {in}}-W_{\rm {out}}=W_{\rm {net}}} {\displaystyle Q=Q_{\rm {in}}-Q_{\rm {out}}+W_{\rm {in}}-W_{\rm {out}}=W_{\rm {net}}}
For the particular case of a thermally isolated system (adiabatically isolated), the change of the internal energy of an adiabatically isolated system can only be the result of the work added to the system, because the adiabatic assumption is: Q = 0.
{\displaystyle \Delta U_{\rm {system}}=U_{\rm {final}}-U_{\rm {initial}}=W_{\rm {in}}-W_{\rm {out}}} {\displaystyle \Delta U_{\rm {system}}=U_{\rm {final}}-U_{\rm {initial}}=W_{\rm {in}}-W_{\rm {out}}}