Hello every body ,
upto now i saw advantages of C# only,i am curious about what are the
disadvantages of C#..(because any programming language should have some
positives and negatives..)
Thanks
Chandu
Well, first of all it's a compiled language (with the pro's and con's
of that) as opposed to a script-language like Python. Secondly it is
compiled to Common Intermediate Language (CIL) so there is a second
"compilation": JIT (just-in time compilation). This makes it something
in between a script language like Python and a "native" language like
C - again this is comes with both pro's and con's. Python-people (and
others) tend to seem script-languages are faster for developing and
more flexible when updating parts of the system (no need to store
stuff in the GAC I guess). On the other hand I think complied
languages are little more robust and I guess faster since they are
compiled.
Since it is compiled to CIL you can pretty much extract your source-
code from f.x. an exe-file, a typical tool for this is Lutz Roeders
Reflector. This can be considered positive sometimes, and negative
sometimes.
An advantage of the CIL-stuff is that is can interface with all
classes and libraries of the .NET platform. As I see it this is the
main advantage of C# and any other .NET-language.
Since Microsoft is pretty much behind C# I fear, and at least some
people with me, that C# is a sort of "flavor of the decade" language -
meaning that in five to ten years it will be dead and replaced with
the next Microsoft "flavor of the decade". Compared to C that is a
very stable language that has been around for about 30 years and has
looked pretty much the same C# will not look like it does today in 10
years if it exists. (My personal opinion/guess/fear.)
Also, since I like conspiracies I think Microsoft is doing this to
make money (perhaps not only but at least partially), it must be nice
for them to force people to buy new stuff, reprogram that stuff and so
on at least once a decade. BUT: If you ask Microsoft they will reply
that they want to invent new stuff and lead in the technology race
instead of being second. And of course they are right. C#/.NET would
not be as excellent as it is if it had not been for the extreme effort
they have put into it. But still: I fear that C# will be a dead
language in 10 years (replaced with a new C-flavor), but that C will
still be running strong. (On the other hand the .NET framework seems
to be really important so I dunno really.)
When it comes to syntax you could perhaps prefer visual basic or some
other .NET-language, but that is a matter of taste (since C# and
VB.NET have (I guess) identical functionality).
HTH,
Per