Time and Space Bounds for Planning