moving obj while holding a key

Does anybody know how to move an object by arrow keys only while I am holding it using python script?
I tried to add “Rightarrow” sensor and activate the motion actuator when the sensor is “isPositive()”, but this makes the object keep moving upon a single key stroke.

Python doesn’t know what to do when isNegative().

Does it help?