Software Development
Blogs and Discussion
developer.*
Books Articles Blogs Subscribe d.* Gear About Home

I find the great VB.Net versus C# .Net debate rather tiresome

...because throughout history, second-rate intellects have proclaimed the superiority of one natural language over the other.

French is considered by the xenophobic, conservative Frenchman was considered to be more "clear and logical" than English or German. This is a language in which "personne" abbreviates "no personne" and in ordinary speech, when I say "personne n'aime Bush" I don't mean "there exists at least one person who likes Bush": I mean nobody likes Bush.

Of course, this telegraphic shorthand, while it would be ambiguous in a programming language, is perfectly acceptable in speech because (1) many personnes understand it in context and (2) the usual Gallic tonality and shrug, coupled with the Gauloise being lit communicates the meaning.

The problem seems to be that a "language" is thought to be approximately yet ideally a set of rules which the "proper" speaker has mastered and as such rather close to what a programming language is, in reality.

The paradox is that a programming language is best mastered in the dull way NATURAL languages are taught, at least until the teacher of the natural language throws in the towel. Harold Ramis in the 1981 film Stripes, an account of two losers who join the Army and conquer a piece of Communist Bulgaria, starts the movie as a hapless teach of English as a second language. His English class following the rules but ends it leading the class in a chorus of "son of a beetch: boolsheet" because it's hopeless to teach context-free "correct" language as rules.

Whereas too many CS teachers try to teach programming languages as NATURAL languages should be taught, as "praxis" in which the students struggle blindly to code a program that says "hello world".

The PROGRAMMING language should be taught as rule-driven and it is a crime never to release a complete Backus-Naur Form definition of a language, as Microsoft never did for VB (it has for VB.Net). The HUMAN language such as French should be taught as part of a mad French holiday in Paris and at the beach in Nice, with only one rule: Francais ont parle seulement.

Mistakes should be forgiven on French leave during our gay little holiday as long as meaning is imparted: "venez au moi, au Casbah" is not a French error so much as risky in an era of militant Islam.

Whereas in programming mistakes should be pointed out with a gentle persistence.

However, les chauvinists of the language they speak as natives, as *pieds noirs*, are great ones for correcting others in the small and in the large, for the grand insistence of a mystified Occidentalism in which the West in general and their language in particular, is removed from time and chance and endowed with special power.

Which is why the VB versus C# debate is so wearisome.

The chauvinist of natural language is all to often deaf to his own language when it uses unfamiliar words and complex syntax. He moves all too readily from beating his servants for speaking Arabic to denouncing the student on the tram, who speaks his own language but with complex elocution or a pronunciation more refined than his.

The Mandarin chauvinist is a great one for the Four Tones and laughs at the Westerner for not using them correctly. But when greeted with Ni Hao, he in fact doesn't say Ni Ha (o) with a falling and rising inflection. He says it in jazzy (Western influenced) style as ni, ha.

[Some personal bile here! I am struggling with Chinese for Today and the blasted Yang Fang at the bloody airport meeting Mister Chen shi ba in a context free, ahistorical encounter drained, like most language texts are drained, of interest, passion, fear and desire. I learn more by getting my cab fare down at Lo Hu because the guys that get the riders are desparate migrants and it places me in a genuine human context...where my "wu shi" makes them laugh in friendly scorn, and we always converge to ba shi especially when I cannot remember how to say 70,]

On a parallel track, the C# chauvinist hasn't in many cases learned computer science and relies instead on the language to tell him how to program. In my experience, the result is (for example) Inheritance reborn as farce.

C#, in foregrounding inheritance (in contrast to VB), results in a repeal of the death tax and inheritance used with wild abandon. In one example I saw, a Windows form inherited an array.

What this means is that the form "is an" array and it is poor design; in the actual case I saw, the form was only incidentally interested in this array and had other business to attend to, and it was just laziness and fashion that resulted in the code.

I have no special fondness for, nor brief for, VB, because that would make the parallel mistake, just as Islamic societies assert their superiority to the west.

VB, to begin with, does not allow, as do languages in the C family, the creation of blocks "at will".

Algol 60 invented this very useful concept in the form of what appear to be keywords but which are best thought of in Niklaus Wirth's phrase as fat parentheses, begin and end, and in the Algol 60 "publication language" were in boldface to show this role.

The elegant and easy to remember the rule is that in all contexts, a begin..end block (which becomes a block surrounded by curly braces in C-like languages) is orthogonally a statement and has full rights to appear in place of any "simple" statement.

This rule's value took a long time to sink in because it equates the "complex" with the "simple" at a high level and the rule acknowledges the programmer's core task...which is mastering complexity.

It may have taken a long time to sink in in America and in American-dominated computing cultures because of Frederick Taylor's "scientfic management" and its influence in American industry.

Taylor, in the 1920s, insisted that the most efficient work-man was one told only a small part of the job on which he had to focus.

Taylorism as applied to programming equates the actual coder with a low-level workman who ideally will focus only on a predfined task. This ignores the possibility that a programmer may create highly focused and modular CODE while himself being made aware by a more participatory management of the big picture. This has created the paradox of diffuse, confused, unfocused and unmaintainable software...created in the usual case by programmers who have been pre-focused by a Taylorist management almost as a passive-aggressive gesture.

Industrial discipline pursued as an end in itself creates anarchy on the ground.

Fortran and other IBM-sponsored languages like Cobol were innocent of block structure, as was Basic. In the case of Fortran and Cobol, it was expected that "high level" people would have requirements typed out on IBM Selectric typewriters from their Dictaphone tapes by women, that these requirements would be sent to the programmers-in-cubicles, and that given their "high level" clarity, the programmers would silently and obediently write down single, flat modules that would then do things such as control remote terminals and indeed consitute very large, apparently "intelligent", operating systems such as OS/360.

[I am not making this up. I was there.]

In this context, any attempt at "factoring" code into a better structure was a termination offense...at least until management realized, for example during the development of Multics at MIT and OS/360 in beautiful downtown Manhattan, that the whole system was dysfunctional.

One manager was Fred Brooks, now a college professor at UNC Chapel Hill, and his honest ruminations became the software classic The Mythical Man Month.

Visual Basic, unlike C#, emerged at first from this Dark Age and as a first language it teaches incompetence at warp speed.

Therefore I have no special brief for VB.

However, I think that "language wars" are an artifact of a new computing dark age created by the decline, in the US, of computer science enrollment and a sharply anti-intellectual culture created by the Bush administration, in which a smirk can replace knowledge.

Well founded anxiety about one's personal competence creates language chauvinism just as Le Pen supporters in France and militia members in the US are not rich, only anxious about their position in society.

The major problem remaining in VB is the fact that a series of (newline delimited) statements cannot in general be bracketed to make a statement, although there's a question as to whether this change would be worth the effort. As it is, blocks are created in VB in certain statements added when Basic developers realized that Basic needed to support structured programming, such as If Then Else, For and Do While.

But beyond this, the brutal truth is that the CLR enforces commonality and language is a lifestyle choice.

Categories:  | | |

True, but I still prefer C#

At the job I had before my present gig, I had to write a framework to support dynamic reskinning and branding of a series of websites that would drive off the same code base. All the customers wanted the same basic functionality, but they wanted it to have their own look and they wanted to choose from two different layout/nav schemes. For this, it was required of me that I use VB.NET. I had had no experience with VB.NET (though plenty with VB 6) and had been using C# exclusively since Beta 1 of the .NET Framework came out. To be sure, the VB.NET language was never a roadblock to accomplishing anything in my design. However, I do feel it went along slower than it could have had I been able to code in C# simply because of the time I spent looking up the VB.NET corrolaries for things like overriding methods, interface implementation and so on. One of the most compelling arguments I have heard for C# over VB.NET is that it's closest in syntax to C++ and Java where most folks who've had OOA/D experience prior to .NET have cut their teeth. Makes sense to me. I also like that C# is less verbose than VB, but if VB is your background, then VB.NET will let you do anything you want.

Also I'd kind of take issue with this:
"C#, in foregrounding inheritance (in contrast to VB), results in a repeal of the death tax and inheritance used with wild abandon."

That's a little extreme. Just as it's not the fault of the gun should the owner shoot his/herself in the foot, it's not the fault of the language that it provides polymorphism and inheritance to folks who don't know the difference between an abstract class and an interface. Developers who want to use advanced features like these and multi-threading should take the time to learn about those features instead of shoe-horning them into a project where they don't apply so that said developer can put said feature on his/her resume.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Recent comments

User login

About our advertising.

Atom Feed

developer.* Blogs also has an Atom feed, located at this url.

Click here for more information about Atom.

A Jolt Award Finalist
Software Creativity 2.0
Foreword by Tom DeMarco

Recent Posters

Based on most recent 60 days, sorted by # of posts and name.

Google
Web developer.*

Who's online

There are currently 1 user and 19 guests online.

Online users

Syndicate

Syndicate content
All views expressed by authors, bloggers, and commentors are their own and do not necessarily reflect the views of developer.* or its proprietors.
Click to read the Copyright Notice.

All content copyright ©2000-2005 by the individual specified authors (and where not specified, copyright by Read Media, LLC). Reprint or redistribute only with written permission from the author and/or developer.*.

www.developerdotstar.com