Question

Need help to decide to learn C# or not

Asked by: erwins

Hi,

my expertise is in the grandfather languages of FOCUS, COBOL, C  and I want to retool and learn something more current.

C# has peaked my interest, but I have a few fundamental questions about it before I decide to dive head first into learning it.

1) Is it a compiled language or is it interpreted?
2) What is its relationship to ASP .NET?  I hear about the 2 together a lot.  Do I have to learn both?
3) I hear that web apps can be written with C#, but can it be used to write stand alone apps as well?  And client server apps also?
4) I hear C# is Microsoft's version of Java after their attempt with J++.  How does it compare to Java in performance, speed of development, ease of learning, enterprise capability, security, etc?  I ask this because I'm thinking of learning either C# or Java so knowing the pros and cons of both will help me decide.
5) Will a C# app run on non-Microsoft platforms like Unix, Mac?
6) Is it low level (powerful) enough to use for game development such as action games with lots of animation or should I use C and C++ for this?

I know these are a lot of questions, but I thought it would be easier to consolidate them into one instead of submitting each one separately.

Thanks in advance,
Erwin

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2004-05-20 at 00:22:36ID20995827
Topic

C# Programming Language

Participating Experts
7
Points
500
Comments
19

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. Java fundamentals
    Sir,Java and C++ ,both are Object Oriented Programming Languages. Let me know what are the Similarities & the Differences between Java & C++.
  2. Language Fundamentals
    1. What is the Difference between a Scripting Language and programming Language?
  3. Learn Oracle
    All, I'm trying to learn Oracle, The software is very expensive, is there any workaround for this? if there is trial or developer version ( like SQL server) or cheaper way? Thanks

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: WiBPosted on 2004-05-20 at 01:09:30ID: 11115384

Well :)
I won't answer your questions, because everybody here can (and will) do it.
And because real proframmer can't limit himself knowing only 2-3 programming languages.
But if the only your purpose is to develop action games, I wouldn't choose C#.

 

by: mail2dollyPosted on 2004-05-20 at 01:27:09ID: 11115459

Hi Erwin,

If you had just looked around a bit, you would have easily found answers to your qu and wouldn't need to ask some of tehse fundamental things. Anyways here are some answers:

1) Is it a compiled language or is it interpreted?
C# is compiled. You need a csharp compiler [csc.exe] which is freely downloadable with the .NET SDK.

2) What is its relationship to ASP .NET?  I hear about the 2 together a lot.  Do I have to learn both?
C# and ASP.NET are two different things. ASP.NET is for web programming. ASP.NET lets you seprate the UI from the code. The code part si written separately in what is called the code behind from the html part. Codebehind can be written in any language supported by the .NET platform. [C# is one of them]

3) I hear that web apps can be written with C#, but can it be used to write stand alone apps as well?  And client server apps also?
Yes, sure C# is used for such apps.

4) I hear C# is Microsoft's version of Java after their attempt with J++.  How does it compare to Java in performance, speed of development, ease of learning, enterprise capability, security, etc?  I ask this because I'm thinking of learning either C# or Java so knowing the pros and cons of both will help me decide.

Lots of differences. Superficially they appear identical, but the internal GC algorithms to the nature of compilation/interpretaion is different. C# is compiled, so it wins in terms of speed and performance over java.
Ease of learning - both should be ok since you are from the C++ background.

5) Will a C# app run on non-Microsoft platforms like Unix, Mac?
Yes it will run on Unix and Mac OS.

6) Is it low level (powerful) enough to use for game development such as action games with lots of animation or should I use C and C++ for this?

It depends, but if you are very concerened about performance then C++ would be my choice over Java and C#.

HTH,
Dolly

 

by: AlexFMPosted on 2004-05-20 at 01:48:43ID: 11115534

1) Is it a compiled language or is it interpreted?

C# compiler converts C# code to Intermediate Language (MSIL), this is similar to Assembly, but relatively high-level. C# exe file (which contains MSIL code) is not true executable file. MSIL is converted to actual executable code when C# exe file is loaded by .NET Framework - this is called just-in-time compilation.
C# code used in WEB pages (ASP) is interpreted.

6) Is it low level (powerful) enough to use for game development such as action games with lots of animation or should I use C and C++ for this?

DirectX is available in C#. But C++ still has better performance.

 

by: mail2dollyPosted on 2004-05-20 at 01:57:29ID: 11115567

"C# code used in WEB pages (ASP) is interpreted." - C# is compiled even if it is written as code-behind of a ASP.NET application. So saying that it is interpreted is wrong.

"C# compiler converts C# code to Intermediate Language (MSIL), this is similar to Assembly, but relatively high-level. C# exe file (which contains MSIL code) is not true executable file. MSIL is converted to actual executable code when C# exe file is loaded by .NET Framework - this is called just-in-time compilation. "
While this is true, only the first time you run the C# assembly it takes time, from then on the execution is faster [its output is cached]. You may want to write simple sample proggie to see this. And JIT is just an option.

 

by: AlexFMPosted on 2004-05-20 at 02:21:28ID: 11115678

This article contains all details JIT:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndotnet/html/dotnetperftechs.asp

See:
The JIT
The Basics
When Does Code Get JITed?
Myth: JITed Programs Execute Slower than Precompiled Programs
JIT-Only Optimizations
Precompiling Code (Using ngen.exe)

C# is not real executable and not pure interpreted langauge. This is other technology, which has both features.

 

by: AdrianJMartinPosted on 2004-05-20 at 05:23:20ID: 11116542

An important point about c# is that it is just ONE of the languages supported by the CLR, as you already have COBOL experience you might like to take a look a NetCobol From Fujitsu. Learning CLR and CTS is probably more important than you language of choice. Assemblies created in one language should interact seemlessly with other assembleys created in another.

http://www.adtools.com/products/windows/netcobol.html

http://www.c-sharpcorner.com/Code/2002/June/WelcomeCobolNet.asp



 

by: _TAD_Posted on 2004-05-20 at 06:25:12ID: 11116975



If you were thinking about creating action games with a lot of graphics, C# is a better choice over Java....  but still not the best choice.  I would have to go with classic C++ for that one (c++.net is nice, but it is still compiled to MSIL and you can't necessarily do all the pointer arithmetic in C++.net like you can with classic C++.


That being said, you could develope your game engine in C++ and then code the rest of the game in C#

 

by: gregoryyoungPosted on 2004-05-20 at 08:14:28ID: 11118034

before I answer let me address some of the other answers

Mail2Dolly: "Lots of differences. Superficially they appear identical, but the internal GC algorithms to the nature of compilation/interpretaion is different. C# is compiled, so it wins in terms of speed and performance over java. "
Java has JIT as well so I am curious what  you are talking about ??

Mail2Dolly: "5) Will a C# app run on non-Microsoft platforms like Unix, Mac?
Yes it will run on Unix and Mac OS." Have you tried this ???

AlexFM: "C# code used in WEB pages (ASP) is interpreted." please explain, last time I checked the pages were being compiled into temporary classes.

1) Is it a compiled language or is it interpreted?
Compiled

2) What is its relationship to ASP .NET?  I hear about the 2 together a lot.  Do I have to learn both?
No you do not but its another tool in your arsenal

3) I hear that web apps can be written with C#, but can it be used to write stand alone apps as well?  And client server apps also?
Yes and yes ...

4) I hear C# is Microsoft's version of Java after their attempt with J++.  How does it compare to Java in performance, speed of development, ease of learning, enterprise capability, security, etc?  I ask this because I'm thinking of learning either C# or Java so knowing the pros and cons of both will help me decide.
They are nearly identical

5) Will a C# app run on non-Microsoft platforms like Unix, Mac?
Sort of if you stand on one leg jump up and down while holding your breath. Superficially they will but you have to be very careful in what you do in code... Take a look at the mono project, they are well underway but are still far from actually supporting the entire framework.

6) Is it low level (powerful) enough to use for game development such as action games with lots of animation or should I use C and C++ for this?
C# or Java would not be your ideal language for this purpose, in fact OO would probably not be a good idea here. Last I checked the industry standard was C/Assembler for this.


 

by: Timbo87Posted on 2004-05-20 at 12:22:29ID: 11120729

Web apps written in ASP.NET will work on any platform because the compilation is done on the server and IIS just returns HTML.

 

by: Timbo87Posted on 2004-05-20 at 12:23:50ID: 11120745

By the way, as was said above, C# syntax is the same as ASP.NET syntax. ASP.NET just has some web related extras like Response, Request, Session, etc.

 

by: _TAD_Posted on 2004-05-20 at 14:26:31ID: 11121904

gregoryyoung>

In reference to .Net speed Vs. Java Speed...

I read somewhere (I'll have to find the source) that both Java and .Net are compiled into some kind of Intermediate language (IL).  Which is just a step or two above machine code... kind of like compiling it to an assembler type language.

At anyrate, I had read that at execution time, .net coverts all code from MSIL to machine code for each dll (er... or something like that), where as Java interprets each line of IL code as it is being executed.  So Java will execute faster for very small programs where .Net will execute faster for medium to large scale programs.

I'll find the source... I'm sure it was on one of MS's propaganda web sites touting .net.

 

by: gregoryyoungPosted on 2004-05-20 at 14:29:46ID: 11121926

TAD

You are correct on the IL (byte code)

Java can either be interpreted or JIT the way .net is ... in fact JIT was around for Java long before .net came out.

Greg

 

by: gregoryyoungPosted on 2004-05-20 at 14:30:48ID: 11121940

 

by: _TAD_Posted on 2004-05-20 at 14:47:14ID: 11122059



Performance:


Java faster than C# in TCP socket performance
http://www.cs.nyu.edu/rgrimm/one.world/csharp/network.html

MS Propaganda - C# faster than Java for a full app.
http://www.gotdotnet.com/team/compare/petshop.aspx

Sun Propaganda - Java 1,000's of times faster than any other language
http://www.javaperformancetuning.com/news/qotm028.shtml


Also on one of the web sites someone was complaining that performance metrics were taken using Java's BigDecimal class to compare to C# large number class.   BigDecimal is a crappy class to begin with, not very usefull, almost never used and it was implemented badly.  (At least those were the arguments).

Ultimately, as far as speed goes... a lot has to do with the developer's skill.... and then of course, using the right tool for the job.  Use C or C++ for your game engines and then build the front end in Java or C#.  Just like Perl should be used for string manipulation...  

 

by: gregoryyoungPosted on 2004-05-20 at 14:49:31ID: 11122082

or awk :)

 

by: gregoryyoungPosted on 2004-05-20 at 14:51:12ID: 11122102

ok ignore the petshop article ... or step into a religious war ... this makes BSD vs linux look like a small skirmish :)

 

by: erwinsPosted on 2004-05-20 at 21:09:09ID: 11123852

Hi Folks,

In defense of seeming to be lazy and asking all these questions in this forum, I have done some research on some of these questions already and have been getting conflicting information.  Hence the need to ask them again to all you experts on this web site.  For example, my question on whether C# is compiled or not.  I suppose I should have refined the question to ask," Does the compiler compile it completely to machine code or does it go halfway to MSIL?".  Well, now I know the answer.

Thanks a lot for all your answers!  They were all very helpful.

Erwin

 

by: mail2dollyPosted on 2004-05-20 at 22:40:47ID: 11124142

Hi GregoryYoung,

"Java has JIT as well so I am curious what  you are talking about ??"
To quickly point two differences:
1. C# can have real pointers, you could work with memory addresses, increment them, move around in memory etc. You could force the GC not to collect these pointer objects - tell me how you would do that in java if there was such a need.
2. The GC algorithms are different. Earlier versions of java worked on reference count basis, where if A had a ref to B and B a ref to A, then even though the two references couldn't be accessed directly from the program in any way, they woudln't be cleaned up. Well, that has been just patched with a work around. Whereas the .NET GC assumes that all objects are to be garbage collected, It then marks out all objects that are being referenecd and leaves them out and collects everything else. That is the underlying algorithm, so superficially though things appear to be the same [like both are GC enabled], their internal implementation is quite different making one perform better than the other in many situations.
And you may want to take a look at some third party benchmarks: http://www.gotdotnet.com/team/compare/

"Mail2Dolly: "5) Will a C# app run on non-Microsoft platforms like Unix, Mac?
Yes it will run on Unix and Mac OS." Have you tried this ???"

Yes download Rotor, [it comes with the C# compiler source code] - I have seen it work on windows and Free BSD. I don't have MacOS but I know it works there too. Of course you can't use windows specific namespaces like win32 registry etc and expect it to run on the other platforms. But, outside of these specific OS dependant libraries, things would work on these 3 OS'es.

The way .NET is built adding a new processor support is just a matter of converting the MSIL to the corresponding processor dependant machine code.

Dolly
http://dolly.thinkingms.com

 

by: gregoryyoungPosted on 2004-05-20 at 23:04:34ID: 11124224

mail2dolly: I was referring to this line .. I know the differences in pointers / GC algorithms ... "C# is compiled, so it wins in terms of speed and performance over java."

second point ... LARGE portions of the framework are not yet moved over so its difficult to write a large application that is something resembling cross platform functional.

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...