I am a new programmer and learning c++. I started on microsoft visual studio.I want to know the common differences between C# and C++.I also want to know the main advantages and disadvantages of both the languages.Does C# code is more complex? If so then why some people prefer c# now a days ?
Want to know difference in C# and C++
Hi
Â
Please take a look on the below mentioned point of difference:-
Â
1. C++ is a neutral and low level programming language. Whereas C# is exclusively designed to be used in .net platform and it is also a high level language.
2. C++ has the concept of function pointers but the similar function called Delegates in C#.
3. C# is updated, modern and programmer friendly language as compare to C++.
Â
C# is anyway better than C++. As it is an updated and modern technique with great programmer friendly. Below are the some of the advantages of C#:-
Â
1. Refuse collection
2. Compilers with array bounds checking
3. When a virtual method is called within a constructor, the method in the most derived class is applied
4. Conditional functions
Â
Advantages of C++:-
Â
1. Better application performance.
2. Portability
2. Multiple inheritance is supported
3. Power to enforce consent-correctness.
4. Allows default arguments for subroutine parameters
Â
Thanks,