|
Answer» Both VB.net and C# use Object Oriented PROGRAMMING Language and run on the .Net framework. These High-Level Languages are also referred to as Common Language Infrastructure (CLI) languages which means their code need not be translated while getting executed on a different platform. Although they have many things in common, their MAIN differences are as follows. C#- C# comes with all the features of Python, Java, C++, and other languages since it is evolved from C.
- To declare variables, the users must DEFINE their own variables or use the built-in types.
- By using keywords in C#, unmanaged resources can be released.
- Optional parameter is not supported in C#.
- C# allows NEW implementation without overriding the base class member. The base class member can be used in a derived class just with the keyword ‘new.
VB.net- VB.net is user-friendly since it uses mnemonics and is much similar to the English language. It can be easily learned.
- To declare variables in VB.net, classes, Private, Public, Protected, Friend, and Static must be used.
- The feature of releasing unmanaged resources is not available in VB.net.
- An optional parameter is supported in VB.net.
- In VB.net, a new implementation of base class without overriding the base class member is allowed. The base class member can be used in a derived class just with the keyword ‘SHADOWS’.
|