Besides the moral issue wheter this is concerned cheating or not, it can also get this student in problems.
I helped out a friend once who had to hand in some Perl homework. The problem was that I'm a selfthaught Perl l-user. I don't obey certain rules (of formatting code for instance) that the student is supposed to use. Besides that, the professor found it slightly odd that this student -who just started the Perl course and wasn't very good at yet- came up with code containing `map` and likes ;)