I am not a student, but I know other avenues have had problems in the past with students trying to get others to do their work for them. I am sure most of the people on this site right now would not give a student the code they need to complete the assignment, but would help them out so that they can do the assignment themselves. What is the official policy on this though?


13 Answers 13


I spend a lot of time on other programming forums and it seems most people agree with the policy "no homework solutions; nudges welcome".

Basically, if the student posts the entire assignment then asks for a solution, it's the same thing as a non-student posting, "My boss wants a blog engine in two months. It has to be in PHP and work just like Wordpress. Please email me the codes at ..." It's going to get ignored or maybe ridiculed.

However, I've seen plenty of students post in a form like: "Here's the assignment. I've done these parts posts sample code. I'm having a little bit of trouble with some task. The documentation says something but it's really not clicking. I tried sample code but for some reason unexpected results happen. Could someone tell me what I'm doing wrong?"

I like to answer these kinds of questions, and the fun is answering them in a way that leads the student to the answer without writing any of the code for them. The student here is really trying, and got halfway by himself before getting in too deep. Gentle nudges are awesome to struggling students; it's when you write the assignment for them that things go wrong.

(late edit): For particularly difficult problems, I personally like to show the student a full solution to a similar but different problem. For example, it's easiest to explain sorting algorithms with actual code. If the student's problem is sorting names in a particular order, I might post a solution for sorting integers. You'd be surprised how many people can't go from one to the other, since it requires more effort than a copy and paste.

  • 2
    Slick answer, I had to say it! This is the exact same attitude that people should try to adopt when replying to a student that tried hard! Because, giving them the solution won't help them.
    – ForceMagic
    Jun 23, 2012 at 3:01
  • Good answer, but this applies to hardware answers as well as software answers. Show me your schematic!
    – Seamus
    Feb 5, 2021 at 15:43

My policy is that if I suspect you are being lazy, I will not help you.


My personal policy - I'll provide tips and pointers, but I'm not going to write a line of code for your homework.


Homework, business work, or hobby work, we're all here to help each other... within reason.


My two cents...I agree with the others, and I have seen this come up in other places where there seems to be a bias and distrust against students, which is understandable I think, but it raises a few questions when considering such a "policy"...

1) How do you know it's a student asking for a homework assignment? Granted, in some cases, it could be obvious, but some assignments (like a database course) could easily be seen as a real-world problem.

2) If a student is asking for help on a specific problem (very specific), what makes them any different than any of us? They are asking for help on something just like we are. Aren't we just trying to learn too? Solve a problem too? There will always be short-cut takers out there who just copy/paste code and don't take care to learn, but whose to say some pros are any different!!??

3) Can't one argue that if a student is reaching out to the net and using resources like StackOverflow,that they are "acting" as pros? Seems to me that's more real-world than when I was in college and the Internet was just a little toddler.

4) How do you measure intent in these cases?

Again, I agree with the others, a case-by-case assessment is sensible, but it's an interesting question :) Cheers.


I would answer someone if they had a specific question where it showed that they have done some work themselves and were just stuck on something.

For example, if someone said "I've got a homework problem I'm working on and I've done X and Y but now I'm not sure how to handle Z" then I'd be likely to answer.

If someone shows up saying "My homework is to solve X problem, someone please give me the solution" then I would ignore them and give them a down vote.


I've asked beginner questions myself (and there is not that much difference between a beginner question and a homework question really), and my own personal policy is: As long as it's a specific question, I'll be willing to answer it.

So stuff like "Here is the assignment, it needs to do X, Y, Z" is ignored by me, but if the person specifically asks something about X, I have no problem answering.

At the end of the day, I don't care if it's homework or if it's business code and I don't care if it's beginner or pro level. I care if it is a real and specific question. Because in order to ask a specific question, the author already needed to have some understanding about the task.


This is something that will have to happen on a question to question basis. If it looks like a homework question then decide if your going to answer it or not, I don't think that there is an 'Official Policy' for this nor do I think there should/will be one.


If they are legitimate programming questions, for homework or not, then I have no problem with it. If what is being asked is for others to do the work for you, whether for homework or not, then those are not cool.


If the question is an interesting one in its own right, and I think that my answer will be beneficial to the community at large, then I don't really care about the motives of the questioner.


That it's not our responsibility to babysit everybody who visits the website. If the person comes here thinking they're doing themselves justice, then they deserve to get beaten with a silly stick when they can't figure out why they're not feeling any improvement in their studies.


You mean like... how to solve Fizz Buzz?


I noticed that there were alot of concept and many more beginner questions being answered when school started about 2 weeks ago (around here, at least).

I would like to think that questions pertaining to homework would be pretty easy to sniff out. For example, if someone asked "How to concatenate Strings in Java" I would be inclined to think that they had gotten here from google and would likely take our code on blind faith. Questions like that do not lend themselves to 'pointers' or 'tips' per se.

However, if someone was working on (for example, a previous homework of mine) writing their own malloc, and wanted to know how to bump up the pointers for each successive call, that would be fairly easy to give 'pointers' and 'tips' on.

Not the answer you're looking for? Browse other questions tagged .