4 posts about Ref Keyword by 4 contributors.
Know Ref Keyword? Share what you know with developers who are learning it.
Explore the distinction between 'ref' and 'out' keywords in C#. Learn how 'ref' passes arguments by reference for both input and output, while 'out' is used solely for output parameters, aiding in flexible parameter passing and variable modification within methods.
C# ref and C# out keywords are used in method parameters. This article helps you decide whether to use a ref or out keyword, especially when the parameter types are value types.
In C#, the ref and out keywords are used as parameter modifiers in method signatures to indicate how method arguments should be treated. They are often used when you need to pass arguments to a method and potentially receive modified values or multiple values back from the method. Here's a description of these keywords and their usage.
While passing Argument To Any Method Having ref and out keyword in C#.
DevSocialUpcoming · 3rd editionAI Agents ConferenceNov 23–27, 2026Live onlineMembers only16days leftRegisterPublish an article in this category and earn +1,000 SHARP when it is approved.
Write an article