Odd looking carbocation stability order
How to decide whether +M effect or -I effect will operate in this case?


The extent of stabilizing effect follows the order: $\ce{\text{Mesomeric} &gt; \text{Hyperconjugation} &gt; \text{Inductive}}$. 

In general, this order is based on extent of $\ce{e-}$ transfer. In mesomeric effect, $\pi$-bonds are in conjugation which completely transfers $\ce{e-}$ density to carbocation. On the other hand, in inductive effect, induction of charge takes place, which partially transfers $\ce{e-}$ density through $\sigma$-bond. Hence, it is weaker.


  why +M effect of 'N' is more than that of 'O'?


As $\ce{N}$ has lower electronegativity than $\ce{O}$, hence it has greater $\ce{e-}$-donating tendency, therefore greater $\ce{+M-\text{effect}}$