The Difference Between Covariance and Contravariance in .NET C#by@ahmedtarekhasan
2,187 reads

The Difference Between Covariance and Contravariance in .NET C#

tldt arrow
Read on Terminal Reader
Read this story w/o Javascript

Too Long; Didn't Read

Covariance and Contravariance were introduced by Microsoft in C# 6.0. They allow implicit reference conversion for array types, delegate types, and generic type arguments. Covariance preserves assignment compatibility and contravariance reverses it. Microsoft’s definition is different from what you would find in this story.
featured image - The Difference Between Covariance and Contravariance in .NET C#
Ahmed Tarek Hasan HackerNoon profile picture

@ahmedtarekhasan

Ahmed Tarek Hasan

.NET (DotNet) Software Engineer & Blogger | https://linktr.ee/ahmedtarekhasan


Receive Stories from @ahmedtarekhasan

react to story with heart

RELATED STORIES

L O A D I N G
. . . comments & more!