use dict comprehension for blocks