Jump to content

Check out our Community Blogs

- - - - -

C# vs Visual Basic

Posted by CriticalError, in Visual Basic, C# 21 August 2012 · 3631 views

C# Visual Basic Microsoft

Poll: Visual Basic or C# (5 member(s) have cast votes)

Which one would you choose?

  1. C# (4 votes [80%])

    Percentage of vote: 80%

  2. Visual Basic (1 votes [20%])

    Percentage of vote: 20%

Vote Guests cannot vote
I see this every time posted on the forum "VB or C#", "Which is better VB or C#?" and the rest. Both languages Visual Basic (or VB) and C# are made by Microsoft and run of the .NetFramework (basically a library full of pre-written code/commands). Many people want to know especially beginners which one to learn first? Well I personally would say start with C#. There are a few reasons why:
  • Most Microsoft SDKs (Software Development Kit) will always first support C#
Now this is true, when Windows Phone SDK came out it was only supporting C#, that meant that all the examples and every thing were in C#. VB support would be added later.
  • It's similar to other languages
When I learned VB (it was my first language) I tried a C# project and was like what the __ is this? I closed it and went back to VB. Then some time later when I started making my website, I realized that I would need to use C# because there was more code examples and more support. (More people using it). So I learned C# from here http://channel9.msdn...olute-Beginners and then I also purchased a book "Microsoft Visual C# 2010" after about a month I was confident and mastered the basics. I was actually later on surprised how the syntax was similar to PHP/Java. That meant I could learn another language and would not need to worry about syntax problems. When I moved to C# I always forget it was CASE-SENSITIVE! and you always needed semi-colons to end a line and also curly braces {}.
  • It's easy
OK some of you might not agree on this one, but to be honest once you just learn the "grammar" of C# it gets quite easy, it's just like learning English, how we have full stop to end a line, in C# you use a semi-colon.

Now to VB. VB is also good it was very easy to learn, because it is like plain English (well not quite) there is no semi-colons, no curly braces, and it's not case-sensitive! take these two examples

if (condition)
code to execute

if condition Then

code to execute

End if

As you can see VB code is more like plain English, and you might think well that's a better language to learn! Well trust me if you're going to move on to another language after VB I suggest you start with C#. VB is easy but you will find it hard learning other languages then, because other languages like C#, PHP, Java, C++ share the same syntax, while VB does not share it's syntax with any programming language I know of.

Unless you have a good reason to learn VB, then do it, otherwise stay away and learn C#.

  • 1

I prefer terse languages, like C++, so C# is more to my liking.
    • 0
There have been innumerable programmers in the business who had started on BASIC derivatives. "while VB does not share it's syntax with any programming language I know of." You go with the pack because they are similar? Syntax {} is not what should be important in the language. See HASKELL and related, they're not that terse for a reason, but they work.

I liked my quick pseudocode like "sketches" of simple games in VB6/VB.NET to get me interested. I feared C++ though, as VS wouldn't just 'compile' a .cpp, you had to set up a project (which people didn't post project files), made me think C++ Was much more confusing than it was. Learned PHP as my first C-like language which arguably could have made it easier to move to C.
    • 0
I like Haskell and Lisp quite a bit. I don't care whether the start symbol is { or BEGIN or (, because they all mean the same thing. I program in PHP, Delphi, VB, and ColdFusion for my job. I have to use a variety of syntaxes and switch between " and ' as string delimiters on a regular basis.

I just like using fewer characters to start a code block :)
    • 0

Recent Entries

Recent Comments

0 user(s) viewing

0 members, 0 guests, 0 anonymous users

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download