C# Programming

Categories:

Recommended

Although C# is derived from the C programming language, it introduces some unique and powerful features, such as delegates (which can be viewed as type-safe function pointers) and lambda expressions which introduce elements of functional programming languages, as well as a simpler single class inheritance model (than C++) and, for those of you with experience in “C-like” languages, a very familiar syntax that may help beginners become proficient faster than its predecessors. Similar to Java, it is object-oriented, comes with an extensive class library, and supports exception handling, multiple types of polymorphism, and separation of interfaces from implementations. Those features, combined with its powerful development tools, multi-platform support, and generics, make C# a good choice for many types of software development projects: rapid application development projects, projects implemented by individuals or large or small teams, Internet applications, and projects with strict reliability requirements. Testing frameworks such as NUnit make C# amenable to test-driven development and thus a good language for use with Extreme Programming (XP). Its strong typing helps to prevent many programming errors that are common in weakly typed languages.

Standard

Microsoft, with Anders Hejlsberg as Chief Engineer, created C# as part of their .NET initiative and subsequently opened its specification via the ECMA. Thus, the language is open to implementation by other parties. Other implementations include Mono and DotGNU.

C# and other .NET languages rely on an implementation of the virtual machine specified in the Common Language Infrastructure, like Microsoft’s Common Language Runtime (CLR). CLR, for example, manages memory, handles object references, and performs Just-In-Time (JIT) compiling of Common Intermediate Language code. The virtual machine makes C# programs safer than those that must manage their own memory and is one of the reasons .NET language code is referred to as managed code. More like Java than C and C++, C# discourages explicit use of pointers, which could otherwise allow software bugs to corrupt system memory and force the operating system to halt the program forcibly with nondescript error messages.

History

Microsoft’s original plan was to create a rival to Java, named J++, but this was abandoned to create C#, codenamed “Cool”.

Microsoft submitted C# to the ECMA standards group mid-2000.

C# 2.0 was released in late-2005 as part of Microsoft’s development suite, Visual Studio 2005. The 2.0 version of C# includes such new features as generics, partial classes, and iterators.

Category:

Attribution

Wikibooks. C# Programming. https://en.wikibooks.org/wiki/C_Sharp_Programming

VP Flipbook Maker

Make stunning flipbooks online. Create flipbooks for free with Visual Paradigm. Create online flipbooks, design, publish and share your flipbooks online, try it now!