Assuming your question is on-topic, there are three things you need to include when posting a question on Stack Overflow:
1. What your program is supposed to do
2. Your code
3. What your program is actually doing
If you leave any of those three things out, people will have trouble answering your question, so they'll often downvote it and vote to close it instead of trying to answer it. (Ok, I admit it. It's me. I'm the one downvoting you.) Let's take a closer look at each one of these things, and maybe I can convince you why each one is important.