Nasdaq’s August was lousy. How the smart money played it