I'm an undergraduate student. A new professor joined our college this year. The new professor went about asking other department faculty about students proficient in programming and one of the existing faculty recommended me. Now apparently, this new professor is not so good at programming, and wanted someone to implement an idea from one of his already published paper. Now I have been asked to do it and I agreed, cause I like programming. Now my question is, do I stand to gain anything non-trivial from doing this? What would be the proper stuff that I could ask the professor in return for doing it?
This is a perfect situation for you to suggest that if possible you would like to get started on a career that includes publication of scholarly articles, either alone or in collaboration with the prof. Ask him if this project is a good vehicle for this. It assumes either the implementation or an extension of the original paper is valid for publication, of course. You might wind up a big winner. He will, in any case, likely consider you for a future project if this one doesn't seem right to him. There is little to lose.
Don't ask him for a gimme. Ask for collaboration and help in learning how to develop and write for publication.
There are two additional thoughts. Maybe he just didn't think of it, so your approach might wake him up to the possibility. And also, he may put your name around to other faculty who might be willing also. Just expressing your interest can start a lot of wheels turning.