Sensex, Nifty gained after dropping to more than a four-week low on Tuesday. (Reuters)