erasing typos and swapping 'char' for 'str'