- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Wow, I can hear your fapping from here. Surely that must be hurting?
Admin
All Sun did was hold MS to their agreement - adding native hooks to java while calling it java defeats the purpose.
Admin
We must all live up to really important code standards such as putting the right capital letters in the right places. I, myself, as a BrainBench-certified Spelling Nazi, regard this as a given.
Now.
How about the code?
Java and C# code weenies... Pfft.
Admin
Gee, even the dates are strings...
Admin
I've never actually heard masturbation, myself. Do explain to us what it sounds like. Or indeed how it might be relevant.
Admin
Admin
I have seen one of my colleague coded a worse for-switch-case WTF (worse because in that case a list/array followed by a for-loop is really the no-brainer solution). I felt sad for the customer, who thought it was a big WTF also. But the customer, who was my ex-colleague, didn't request the code to be changed, because it was him who hired my colleague in the first place (another WTF) before he left and then became our customer (bigger WTF?).
Admin
Admin
No, that would take half the fun out of it.
Admin
I know you're just a spammer and you should FOAD, but god damnit that it is a good quote.
Spam boy, you just been sig'd..
Admin
Just be glad it wasn't written by a programmer over a certain age (probably about 80) raised in the certain parts of the southern U.S. To my grandparents, lunch was called "dinner" and dinner was "supper".
captcha: none, cos I'm registered, bitches.
Admin
Wow. You really got me there. Your logic is just insurmountable...
ROFL
But seriously, what can you do in C# that you can't do in VB.Net? Abuse select-case statements by leaving out the Break;?
Admin
mierda
Admin
mierda
Admin
malditos idiotas de procresia ladrones de mierda
Admin
malditos idiotas de procresia ladrones de mierda
Admin
Because that version fits the ethnic stereotype's accent better.
Admin
Stupid question: given that list of objects, and the need to set those variables from those objects, and the objects being optional, what's the right way to write that?
Admin
There may be a deeper WTF here with the data retrieval / storage mechanism - for some reason it seems to read a variety of values from somewhere and cast each one into an Object, before putting the Objects in an array in a specific order. That wouldbe a WTF in itself, but could be dealt with more logically by creating 28 sensibly named constants (e.g. private final int DEDUCTION_LUNCH = 13;) to index into the array, and then 28 GetItemname() methods which use the constant name as the index into the Object array, cast the Object into an appropriate type and return it (it may not be the standard in C#, but in Java it is strongly recommended that all class variables are private, and access to them in controlled by getters and setters...)
Admin
You are ending at the wrong place. It's like asking which train to get to, say, West Pinchbeck (a small village I used to live in). I could tell you which train to get, but you'll find that when you get off it you're still five miles from your destination. The problem is you've chosen the method (train) of solving the problem without really considering the problem (getting to west Pinchbeck). In this instance, the method (assiging values to 28 String variables) is a bad way of dealing with the problem (providing access to 28 variables, of various type, which are stored in an Object array at known index values). If you are writing the wrong solution, then there cannot be a "right" way to do it.