Page 2 of 2

Re: lulz

Posted: Thu Nov 25, 2010 6:01 pm
by Arce
Any questions?

Re: lulz

Posted: Thu Nov 25, 2010 6:42 pm
by avansc
I dont wanna get involved in this little tiff, but wtf is "very legit, low-level C code" ?

Re: lulz

Posted: Thu Nov 25, 2010 6:48 pm
by Falco Girgis
avansc wrote:I dont wanna get involved in this little tiff, but wtf is "very legit, low-level C code" ?
I have seen it in code for drivers and a microkernel for an embedded platform, haha.

Re: lulz

Posted: Thu Nov 25, 2010 7:22 pm
by Arce
The topic is actually called "lulz."

C'mon.

Love circle. Now. ;)

Re: lulz

Posted: Thu Nov 25, 2010 7:52 pm
by k1net1k
Arce wrote:
K-Bal wrote:There is more about code than efficiency and correctness. How about readability, maintainability, modularity? I think the examples in this thread are quite understandable, but I wanted to point that out.
Allow me to reiterate:
The reason for all the (unnecessary?) ternary statements is that it allows you to essentially ignore the "design" part and just speed code, "hacking" in extra conditions wherever necessary.
and
But the main thing I was referring to was this garbage:
as well as
Did that really save you any time? :roll:

Of course.
Also,
Hell no! I have seen some very legit, low-level C code using that kind of embedded ternary statement. I think that's perfectly acceptable.
'

was referring to

Code: Select all

           char letter =  ((average >= 90 && average<= 100 ) ? 'A' :
                          ( average >= 80 && average< 90   ) ? 'B' :
                          ( average >= 70 && average< 80   ) ? 'C' :
                          ( average >= 60 && average< 70   ) ? 'D' :
                          ( average <  60                  ) ? 'F' : 'X') ;
hence the
kind of embedded ternary statement.
In regard to
I was also unaware of the fact that Arce was required to write in straight C
Irrelevant? No, non-nonsensical and obviously the retort of somebody who misunderstood the original defense, or atleast drew wild deductions about the whole
I have seen some very legit, low-level C code

to imply anybody implied anything about nested ternaries requiring straight C?
I am also a naive fool
Clearly.
for assuming that including an abundance of the code that Arce's professor is specifically against, is clearly insulting their judgment.
But not for this reason. Perhaps you missed the "lighthearted vibe" of the topic, emphasized by
as "x-treeme nerd!" :)
,
pretty nifty, nonetheless. ;)
,
The ternary operator RULLZ! :worship: You should get a +1 for every ternary you use!
,
Please, direct your attention to the "showResults" mess, and tell me if you think she's going to flunk me? :lol:
pointed out by
Wow, my post might have warranted a sarcastic one-liner, but an entire paragraph complete with multiple emoticons to emphasize the sarcasm?
,
and under the circumstances of
I found myself waking up 15 minutes before an extra credit assignment was due
yet somehow managed to deduce that I was in some way intentionally trying to insult my instructor?

Impressively, you manage to contradict your own logic here
It is apparent that Arce's professor is dimwitted for enforcing that her students produce clean, readable and maintainable code.
with
Especially in a seemingly basic programming course, where the prerequisites would surely be a knowledge of the bare essentials of the language.
; would it not be illogical to argue the simplicity of a "bare essential" course, then swing your own definitions of
readable and maintainable code.
, which is, by and large, a complex topic beyond the scope of
knowledge of the bare essentials of the language
especially when, "showing off" the many uses of a ternary would be clearly demonstrating your
knowledge of the bare essentials of the language
? :roll:

And, finally,
There is more about code than efficiency and correctness. How about readability, maintainability, modularity? I think the examples in this thread are quite understandable, but I wanted to point that out.
this is not necessarily true in the circumstances of some very legit, low-level C code or cases of embedded systems (thought, obviously, this is not applicable here, and we're just arguing for the sake of argument. ;p )
Feel free to correct me, if I am wrong.
Done.

I have nothing to say on the matter as i have no idea what half of this is about, but figured it would be funny to quote this :)

Nested quotes FTW

Re: lulz

Posted: Thu Nov 25, 2010 8:22 pm
by Arce
O.o;;

As I scrolled down, before I read your post, I was thinking about how ridiculous it was that somebody quoted the whole thing. :P

Locked for the sake of sanity.

Re: lulz

Posted: Thu Nov 25, 2010 8:44 pm
by dandymcgee
How the HELL did you get phpBB to allow that many tags in a single post. :shock:
Arce wrote:Locked for the sake of sanity.
Since the OP requested it. :lock: