some algo problems