Thursday, December 27, 2012

Prove that you have tried.

Blog Post 15: Prove that you have tried.

Now, I have been on a Q&A site called Stack Overflow for a while now, and one thing has really been merged into me. "What have you tried?"

It is a common mistake that most newbies make, in this case programming, but it may apply to other occupations. Now, another person (I can not recall his name), wrote a blog post that people have been using about "What Have You Tried." It is a very good post, and I won't lie and say I am not receiving inspiration from that post.

However, I would like to suggest that it is more than asking what have you tried, but instead, prove that you tried.

For example, say I was having a problem, and I searched around for days trying to find a resolution. Well clearly, I had indeed tried, but if I simply posted this question:

"Hello. I have a viewController in my app, and I want to know how I can make the flip transition change it's pivoting point. Any suggestions welcome. Thanks."

People wouldn't want to help. If you look ONLY at that, it would appear as if I wanted to do something, and I am just demanding the code. Although I did try, other people won't think I did.

Now of course, that is very similar to "what have you tried", but this is where it differs. Perhaps you have tried, but you really don't know what you are looking for, and therefore you can't add any code, or any particular website that demonstrates what you need. How would people know you tried? Prove it!

As another example consider this. I asked a question a while ago (Which is now closed, but for another reason.) about how to redirect another android app to your own. It was closed though, so I had to re-write it and it was then opened. What was the difference. Both started the same way, I didn't try to find anything any harder the second time. Instead, the second time I expanding on what I tried. Here is a comparison of the two:



--------- The first time -------
I am creating a web protection browser, and obviously I need to not allow the user to access other apps. For example, Youtube, Google Chrome, and Google Search. How do I redirect other apps to my own app on Android.
I am aware that this will make my app more likely to appear as a virus, as it uses more demanding permissions, but that is fine.


If anyone has any ideas, let me know.

--------- End of the first time --------


--------- The second time -------
I am creating a web protection browser, and obviously I need to not allow the user to access other apps. For example, Youtube, Google Chrome, and Google Search. How do I redirect other apps to my own app on Android.


I am aware that this will make my app more likely to appear as a virus, as it uses more demanding permissions, but that is fine.


I can not supply any useful code because I simply do not know what to use for this. However, as I did not supply enough what have I tried, I will tell you what I think I need to do.


I know there is a permission that allows you to get some information from other apps, and close them if necessary. However, I am not sure how to implement that or how to open mine instead.
I did a search on Android Developers for something like this, but did not find anything useful.
http://developer.android.com/index.html#q=closing%20other%20apps
http://developer.android.com/reference/android/Manifest.permission.html
GetTasks looks like what I need. I looked at K9, and it uses Get Tasks, Kill Background Processes, Read External Storage, Get Accounts, Write External Storage, Internet, and some other ones that don't matter.


So, I really need to know how to use getTasks. Android Developers didn't seem to really have any information on it.


If anyone has any ideas, let me know.

 --------- End of the second time --------

The difference is clear. Although I did not add any code, or perhaps any accurate information, I proved that I tried. I gave my ideas, and some references to possibly useful sites, but perhaps not.

This is the key. Never ask a question that appears to others like you just randomly thought it up and dropped it on them. They have jobs, so unless you want to pay them their hourly wage, don't do it.

Now everyone does this once or twice. Don't feel bad about it. It takes a while to remember this. But before I close this post, I want you to consider when you ARE allowed to ask something without "proving that you tried".

Really the only time you should ask other people's opinion's on something when you haven't tried, is really for stuff about theories or ideas. In other words, if it is related to your code, look it up. However, if you would like to know the best way to do something, then you could ask. Consider:

Is something like (i = 0; i < 10; i++) the only way to write that statement, or is there a better way?

Now, that question may not be allowed depending on where you are asking it, but in most cases, that is a fine question. Obviously, people do not expect you to have tried something if you want to know if it is possible, however more basic questions might get you a "what have you tried?". Actually, it would be more of "Look it up", and then the person that answers is thinking, "What kind of a lazy person would ask such an obvious question. They really couldn't have bothered to look it up themselves."

Yeah, you do not want to do that.

So, in summary. If you are on a programming Q&A site, be prepared to not really provide "what have you tried", but instead, "prove that you tried". This creates a "I see that this person did look around, and they are struggling. I would like to help them out with this."

This might mean providing code, references, or maybe even just saying. "I am brand new at this. I have looked around on the web and on this site, but I can't find anything. I do not expect you guys to hand over the information, but if you could at least give me a place to scrutinize around, I would be so grateful."

Now, get out there and help the world... Or ask a question, which ever one.

EDIT

I found the guy I was talking about. Matt. Here is his website, you should check it out. http://mattgemmell.com/
 

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.