Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

C# C# Basics (Retired) Prepare and Plan Introduction

BOTH JAVA AND C# ARE OOP LANGUAGE SO WHY MICROSOFT CREATE C#??

BOTH JAVA AND C# ARE OOP LANGUAGE SO WHY MICROSOFT CREATE C#??

Randy Eichelberger
Randy Eichelberger
445 Points

The same reason Sun Microsystems made Java when there was already C++. Each language has many similarities, but they also have their own uniqueness. Use the tool that fits the job.

Java has also lost a lot of popularity on the web, getting replaced with Ruby on Rails, the MEAN stack, and ASP.NET due to performance issues.

1 Answer

Steven Parker
Steven Parker
231,269 Points

This is an old question discussed in detail on the web.

But some of the significant differences often cited (in no specific order) include:

  • C# supports language interoperability via .NET
  • C# namespaces are not related to directories
  • C# has properties and indexers
  • C# supports structures, operator overloading and preprocessor directives
  • C# has easy API function access
  • C# has a different implementation of enums
  • C# has generics
  • C# has lambda syntax
  • C# has support for LINQ
  • C# has extension methods
  • C# has null-able value types
  • C# has unsigned value types
  • C# has events

THANKS YOU CLEAR MY CONFUSION:)