Live data from Hacker News

Why Visual Basic is (supposedly) better than C#

simple-talk.com

21–30 of 51 posts

Re: Why Visual Basic is (supposedly) better than C#

#21

You said `&&` is a stupid symbol and `and` is a better one, right? Sorry I think you're wrong because it's a symbol that used in almost all programming languages include c, c++, JavaScript and...

`&&` and `and` have utterly different semantics: `and` does not short-circuit. `andalso` does.

Re: Why Visual Basic is (supposedly) better than C#

#22
post #18

Earlier quoted context omitted.

And `PHP` has it, also! But I didn't see any big application/repository that uses `and` instead of `&&`, honestly.

Since I prefer the Pascal family of languages I do actually like "and", but I will use whatever is the default in a given language. This VB piece seems like a bit of VB programmer crap I usually hear from VB users that only dabble in programming without any proper developer education.

BTW, I think using `and` just make things more human readable, closer to what Martin Fowler says about "Good programmers".

Re: Why Visual Basic is (supposedly) better than C#

#23

Sigh. I'll actually do the job of debunking these one by one. 1. Almost every mainstream language has case-sensitivity. This avoids ambiguity by having only one right way to express a given variable. Since Visual Studio has excellent autocomplete, you don't have to repeatedly use SHIFT, and you are unlikely to accidentally mistype the variable name. Of course, when I see an argument like, "When you accidentally leave…

>Andy ‘Wise Owl’ Brown decided to write a tongue-in-cheek rant whilst he could still remember the pain-points

It's at the top of the freaking article.

Re: Why Visual Basic is (supposedly) better than C#

#24
I used VB for many years and didn't understand why the C# people mocked it... then, about 3-4 years ago I switched and have not looked back.

In my honest opinion, whilst VB is obviously fully supported, C# just "feels" more professional... When you get your head around the syntax, you can seamlessly move between C#/Javascript and many other languages that all follow similar syntax without even thinking.

In addition, there are so many more articles/examples/open source projects and just help out there for it.

Re: Why Visual Basic is (supposedly) better than C#

#25

Sigh. I'll actually do the job of debunking these one by one. 1. Almost every mainstream language has case-sensitivity. This avoids ambiguity by having only one right way to express a given variable. Since Visual Studio has excellent autocomplete, you don't have to repeatedly use SHIFT, and you are unlikely to accidentally mistype the variable name. Of course, when I see an argument like, "When you accidentally leave…

>Andy ‘Wise Owl’ Brown decided to write a tongue-in-cheek rant whilst he could still remember the pain-points It's at the top of the freaking article.

Sorry. Early morning over here. I guess I suffered a reading comprehension failure.

Re: Why Visual Basic is (supposedly) better than C#

#27
The reason I /like/ semi-colons is that I can automate code formatting to my pleasure. If I open someone else's code file and they are doing strange things (e.g. spaces instead of tabs, { on the same line, etc) then I can have the IDE re-format everything in a split second to my preferences, and they can do exactly the same.

Or if the project manager is requiring all code to be formatting a certain way then I can re-format the code before I submit it. Plus with a language you can so quickly and painlessly re-format, why even require code style standards that dictate whitespace?

While some of this MIGHT be possible with VB.net, it is a lot trickier since whitespace is "content" in that language.

Re: Why Visual Basic is (supposedly) better than C#

#28

Sigh. I'll actually do the job of debunking these one by one. 1. Almost every mainstream language has case-sensitivity. This avoids ambiguity by having only one right way to express a given variable. Since Visual Studio has excellent autocomplete, you don't have to repeatedly use SHIFT, and you are unlikely to accidentally mistype the variable name. Of course, when I see an argument like, "When you accidentally leave…

> The author then continues to say that the comparison symbols in C# are "stupid" compared to Basic's "And", "Or", etc. This argument almost doesn't deserve to be addressed

It does. I'm pretty sure VB's "And" and "Or" don't short-circuit…

> 8. The author complains that the type for a variable declaration precedes the variable name in C#. Somehow this is a major problem. Obviously just scraping the bottom of the barrel here.

The author also complains that out-parameters have to be annotated as out-parameters in C#, apparently does not realize parameters don't have to be out-parameters.

> But he retorts that, "The point is that - as so often - Visual Basic makes something easier to code than C# does."

Basically, he complains that C# makes it harder to do the wrong thing than Visual Basic. Which tells you a lot about the mindset.

Re: Why Visual Basic is (supposedly) better than C#

#29

Sigh. I'll actually do the job of debunking these one by one. 1. Almost every mainstream language has case-sensitivity. This avoids ambiguity by having only one right way to express a given variable. Since Visual Studio has excellent autocomplete, you don't have to repeatedly use SHIFT, and you are unlikely to accidentally mistype the variable name. Of course, when I see an argument like, "When you accidentally leave…

10 is weird anyway even if it's satire. System.Array.Resize(ref array, newSize)

Re: Why Visual Basic is (supposedly) better than C#

#30
Don't the point of such "Why eating feces is good" articles. I thought there are some converters from vb.net to C#, if there are none - then rewrite those damn tutorials, you'll end up saving much more health than if you do manual convertion.

Let's just bury that whole idea of 'programming for non-programmers' along with ugly shit that arose from it (cobol, vb, etc).

Post reply on HN