Making slice a Utils function