C# or VB.NET

I have seen post and discussions around the net regarding using C# vs VB.NET.  Here are my .02 on the subject.

First I think a big part of making your decision on what language to choose depends on your background.  The learning curve involved is a big deal when it comes to migrating code.  Migrating to the CLR and .NET is a big enough task in it self to add the overhead of learning a new language.  If your background was VB then I say go VB.NET.  If your background is C syntax like languages (C, C++, Java, etc) then choose C#.  Each language has features the other one does not have.  With 2.0 of C# and VB.NET they are even getting closer to being alike with Generics, operator overloading, etc.  C# has the unsafe blocks so that you can drop down and do some lower level things if you choose.

I have seen and even for my self that if you take a couple programs and compare the IL, that in some cases VB.NET has more IL code generated.  In most cases it is not that much.  This has a lot to do with the compiler teams for each language I think too.  I have my own reasons for choosing C#.  I have a C/C++ background.  I like sticking with what what most of the Microsoft CLR and Framework teams use, which is C# and C++ AFAIK.

I may be way off base here, but what do most of you think out there?  Do you agree or disagree?  I would like to hear your thoughts on the subject.

Published Saturday, May 08, 2004 12:12 AM by bstahlhood
Filed under: ,

Comments

# re: C# or VB.NET

Saturday, May 08, 2004 12:17 AM by Sahil Mailk

# re: C# or VB.NET

Ben: you got it right!

each tool is good, both can do the same jobs in 99% of the cases with no significant difference in the runable code.

the real difference is the coding style of the coder....

My background has several languages so I can use whatever the client wants...

but for most code I'll go with VB unless I need a tight interface to C or C++ or the raw windows API... then my first choice will be C# or managed C++ due to the "extra" stuff they let me do with memory and pointers and related stuff.

Just FYI, my first programing was:

Commodore VIC-20 MS Basic
Commodore 128:
C (yes a real C compiler was written for it complete with a UNIX style shell!)
65xx Assembler (From the old Compute Magazine books -- hand entered from hex listings)
Compiled Basic for the 128 from DataBecker / Abacus software
CP/M 80 on the 128 ( the Commorodre 128 had 2 CPU's one was a Z-80 @ I think 4Mhz... if I recall)
dBase II on CP/M
Pascal
COBOL
FORTH
x86 MASM on DOS 3.xx and later
Microsoft QuickC for DOS V1.00 to V2.51
MIcrosoft Optimising C for DOS V6.00

Many of the first books I read were ones like the Plumb Hall Books on C
Great books that explained arrays, lists, stacks and trees very well....

But here I am using Basic.... cause it's "good ENough" for 90+ % of the time....


Saturday, May 08, 2004 9:08 AM by denny

Leave a Comment

(required) 
(required) 
(optional)
(required)