add baby-step giant-step