use the faster and less memory intensive function