Design And Analysis Of Sequential Randomized Trials With Applications To Mental Health And Online Education