A script to get input with less code.
To use:
Create a empty game object and attach KeyPresses.cs to it.
Select the keys that you want to get input from.
Create a reference to KeyPresses class
Drag and drop InputManager game object to the serialized field. This way Unity will automatically assign the KeyPresses script to the reference called keyPresses.
Now you can check whether the key is beign pressed (KeysBeingPressed), the key was pressed(KeysWasPressed), or the key was released(KeyWasReleased) using the following syntax