Isn't it lay man's?
Anyway, you can't force a key to be pressed, so you would have to do something like:
scancode28=0
if inkey$()="k" then scancode28=1
if scancode28=1 then blah blah blah
Of course you could use a C++ app to synthesize the key, but that's a bit beyond you now.
And about the inputs you posted, if the variable is a string, it can only be typed as a string, and will be calculated as a string, and an integer can only be an integer, same with reals.
So if you had:
Input "Input: ",in
in=in+in
print in
and you input 2, 2+2=4, and 4 would be printed.
If you had:
Input "Input: ",in$
in$=in$+in$
print in$
and you input 2a, it would calculate as a string, addin the two together, "2a"+"2a"="2a2a" and 2a2a would be printed.
If you had:
Input "Input: ",in#
in#=in#+in#
print in#
since reals can have decimals, you could enter 2.4, and 2.4+2.4=4.8, and 4.8 would be printed.
If you have an integer, you can only type 0-9.
If you have a real, you can type 0-9 and decimals.
If you had a string, you could type ant character, which means 0-9, a-z, A-Z, and all the spaces and symbols, but not things like F8 of SHIFT.