I need to type a leftwards arrow, an example as follows:
Is this possible using the keyboard on macOS Mojave?
Use ctrl+cmd+space to bring up the Character Viewer. It is also accessible in edit menu → Emoji and Symbols. Leave the cursor where you want to type and double click on the arrow you want.
Alternatively, The alt codes for arrows can be viewed here on Wikipedia. Have Hex input enabled and active in input sources in keyboard preferences.
For right arrow, hold alt and type 2190. ← will appear.
More standard codes can be found in this table
There are a few ways you can do this:
You can simply copy and paste the unicode 2190 character