Omotodun2's Posts
Nairaland Forum › Omotodun2's Profile › Omotodun2's Posts
1 (of 1 pages)
^ My brother, wetin man go do. I noticed that it usually happens after I have uploaded a pdf file. I also naively thought that as a moderator I would be immune to spam-bot banning, but, alas, oga Seun does not trust his moderators enough to give them that privilege. |
cyclops4real:Sharrap there! I have checked out your profile; aside from the measly two or three PHP boilerplate code that you have posted, how have you helped anyone on NL? |
^ Dude, seriously? Didn't you write the message below? [quote author=naija_swag link=topic=779714.msg9334114#msg9334114 date=1318541477]good thinking good product.nice pseudocode,i followed it and came up with the code below.dealing with p=0 and p = n-1.i know it doesnt run in o(n) time.i have problem analyzing my own code's running time. public class Solution { /** * @param args */ public static int equi(int[] A){ int sum = A[0],sum2 = 0; int p = -1; for(int i=2;i<A.length;i++){ sum2 += A[i]; } if((sum2 + A[1]) == 0) return 0; if(((sum2 + A[0] + A[1])-A[A.length-1]) == 0) return p = A.length-1; if(sum == sum2) return 1; for(int k=2;k<A.length;k++){ sum += A[k-1]; sum2 -= A[k]; if(sum==sum2) return k; } return p; } public static void main(String[] args) { // TODO Auto-generated method stub int[] A = {-7,1,5,2,-4,3,0}; System.out.println(equi(A)); } }[/quote]Seeing as you hate pseudocode, why didn't you attack the pseudocode's author(skydancer)? You even went as far as admitting that it was good pseudo-code; please, quit the doublespeak. We can---if we so desire---solve almost all programming problems, but we'd be doing a great disservice to the programmer since he wouldn't have learnt anything. Saying that the programmers on nairaland who have judiciously decided to teach, not by hand-holding or by outrightly giving the solutions, but by pointing the tutee in the right direction, are half-baked is not only asinine but completely idiotic and unreasonable on your part. Assuming you have had a formal education, did your professor simply hand you the code when you were having problems with your set? I have contributed tons of code on this site; however, I have only done so when it was either a challenge or when it was presenting a faster code to an already solved problem. |
@ OP Chei, see as the spambot dey deal with you. I don tire o. The thing don put me sef for prison. |
@ Oga *dhtml Ludo is not at all complicated. The game is easy to implement. However, if you want to implement a good AI system, then you are in a for big journey. |
@ OP Have you met *dhtml, yawa-ti-de, Fayimora, Beaf, Mobinga, lojik , Slyr0x and others? There are tons of good programmers on this site. |
@ SayoMarvel I was instantly banned after attaching the Java code that you requested. Send me an email at omo_to_dun AT yahoo DOT com if you still want it. |
1 (of 1 pages)