less lists and more in place computation for speed