- 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
The language that's compiled to the same MSIL as C# .NET (assuming you're talking about VB .NET)? It should have it.
Good reading: http://stackoverflow.com/questions/4649423/should-switch-statements-always-contain-a-default-clause
Admin
Brought to you by the symbol umlaut and the number e. Not the letter e, but the number whose exponential function is the derivative of itself.
captcha: damnum - "e is one of those damnums"
Admin
A lot of compilers will spit warnings at you if you don't include a default case... it might technically be fine, but it just makes for better readability (and thereby, more robust code) to include a default case even if empty.
Admin
Yeah, I like that feature. Some people are just OCD about not having ANY line of code that wouldn't change the program by having it removed.
Admin
I learned how to do that in 1966 when I saw this version of Alice in Wonderland on television.
As for the index, the Artists tab in my iPod's music library runs alphabetically from a-ha to 蔡依林.
Admin
Admin
Admin
How naïve. Accents and diereses don't make them different letters. Letters and these modifiers coöperate to indicate pronunciation in ambiguous circumstances.
Admin
that is how I see it: f i=65:1:90 w $c(i)
Admin
Admin
In some languages they do. AFAIK the modified letters in Swedish and (I believe) Danish, for example, come at the end of the alphabet rather than (as you'd expect) next to the letter they are modified from. This can confuse the noob linguist.
Admin
"Just a few years ago".... Googles it Well butter my butt and call me a biscuit, that wizzed right past my head, I was just finished learning the alphabet by then!
Captcha: sino, no, learned that about two years ago.
Admin
True, danish has 3 letters more than common english, æøå... And added to the end of the alphabet.
Though they are relativly new letters, and they used to be written
æ = ae ø = oe å = aa
To make an example, would be like english making a letter to substitute ch with it's own letter because it's used often.
Admin
Seems most people missing the point in the code. There are two independent WTF's here:
A use of a for loop around a case where the case builds up a full list of the alphabet, possibly missing some Swedish, Danish, German, Islandic or other languages characters and not mentioning the code page used. The consequenses of that can ge read in http://thedailywtf.com/Comments/There-and-Back-Again.aspx. I.e this code does not need a for loop or a case statement. just a list of assignment would be faster and easier to maintain.
Why on earth is a list of all English/US characters needed in a database table where two columns contins the same value?
Admin
Admin
This can be directly attributed to the rise of the Internet. The Swedes were sick of having to say Vorld Vide Veb and have everyone mistake them for Transylvanians.
Admin
On the slightly serious side, surely half the WTF here is that he writes a loop and then puts a case statement inside the loop that makes it do something on every iteration anyway. If he eliminated the loop AND the case, and just executed each block of code in turn, the program would be half as long and do exactly the same thing. It would still be stupid for other reasons, but at least it would be LESS stupid.
Really stupid:
Less stupid:
Admin
That makes me realize VB.net (and probably good old VB 6) breaks the case by default. Fitting for high level language. I wish C# and Java had it that way too since those are not bit shifters either.
Admin
Admin
The differences between a C-style switch and a VB select are huge.
http://stackoverflow.com/questions/5891143/c-sharp-switch-statement-more-limited-than-vb-net-case
Admin
Admin