new versiong using list comprehension