This seems to work pretty well!