Multiple choice technology programming languages

_______ Keyword Is Used To Create Aliases For Using Different Versions Of The Same Assembly?

  1. explicit

  2. extern

  3. implicit

  4. internal

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The extern keyword in C# and .NET is used to create aliases for different versions of the same assembly. This is particularly useful when you need to reference multiple versions of the same assembly in a single project. You use extern alias in combination with the /reference compiler option to differentiate between assembly versions.

AI explanation

In C#/.NET, the extern keyword combined with an alias (e.g., extern alias GridV1;) lets you reference two different versions of the same assembly (same type/namespace names) side-by-side in one project, by giving each assembly reference a distinct alias at compile time so the compiler can disambiguate which version's types you mean. 'explicit' and 'implicit' are keywords for user-defined type conversion operators, unrelated to assembly aliasing, and 'internal' is an access modifier restricting visibility to the containing assembly — neither relates to referencing multiple assembly versions. extern (with alias) is the correct, specific C# mechanism for this scenario.