Emulate keypress and hold on 5v detect

Is it possible to use a arduino and have it detect a 5v input and simulate a key press until the 5v signal goes away to a computer where its basically emulating a keyboard. If so how hard is the code? I'm not really a coder. Are there any places live vworker to have this done? Any suggestions or feedback is appreciated.

The Arduino Leonardo can fairly easily emulate a USB keyboard. See: File->Examples->09.USB->Keyboard->KeyboardMessage