If you've copied the question exactly as it should be, then the probability is 0 because, as DWB already said there's a '.' in there which is not available to the monkey!
If you put the '.' there by mistake, or you didn't but it's not a trick question, your answer of (1/27)^39 is correct.*
*This obviously assumes that the odds of hitting any key is the same, and that hitting the same key multiple times in succession is no more likely than hitting any other combination of keys.