|
Posted by Steve on 10/20/06 13:52
".:[ ikciu ]:." <no@mail.com> wrote in message
news:ehaes6$36k$1@news.dialog.net.pl...
| Hmm Steve <no.one@example.com> wrote:
| > 7) NEVER give example of YOUR OWN source code
|
| pfff if you think full solution is better then directions then you are
| wrong, if you will whole time paste code then ppl won't teach anything
| because they will only copy your code, this is not solution
certainly it is logical fallacy to think that the solution to a problem
relates AT ALL to how it is being supplied OR how it will be used! i never
said or asked for source from you save to explain in code what i cannot
understand by your use of english. your 'pfff' is not even disquised
well...it simply is a strawman of your own construction...you tear that one
down yourself.
however you, of all people, SHOULD be supplying code because no one here can
understand your english. code is like a picture, almost speaking for itself.
that's why i asked you to supply some, so i could fully understand how you
planned to implement your solution...because with JUST a description - your
description - your solution won't work (as you originally stated it and only
*recently* modified to look like the two other examples given which DO
work).
not only do i expect for someone to copy the code, i expect that they'll
review it if they want to learn. i supply the full code so that they have
that option. it is not up to me to predict if they want to learn or not.
another plus is that they can see how others approach a problem. they can
also see coding standards at work and decide what they prefer. they can also
pick up new and unexpected goodies like the example i gave in the cell
highlighting thread samples...one purely javascript and one purely php
solution. in that example, everyone said you needed to supply x and y
coordinates of a cell in a grid structure to help solve the op's problem. i
showed that you do not...in 2 lines:
number of columns = 10
selected index = 43
that means (and here's the goodie):
the selected row = selected index / number of columns
the selected cell = selected index % number of columns (% is modulo, icydk)
(selected cell, btw, will be in row 4, cell D [where rows are 0 based and
cells are A-J from left to right]...there are your x, y coordinates without
any muss or fuss)
those calculations solved a BUNCH of problems for a BUNCH of people who had
difficulty expressing (in words and code) how to elegantly solve the
problem. the code i gave was approximately 25 lines of php, is very clean
and manageable, and i certainly HOPE people learn to use those calculations
anytime they have to work with grids!
yes, i certainly think that a FULL solution not only solves the problem but
also imparts MORE than what simple english can...HOW to translate functional
requirements into functional, applicable code.
and damn it if my freaking news reader won't screen out my seeing your
inexperienced drivel!!! i've got to get that fixed.
EOT
[Back to original message]
|