Question

Why should you use properties within the methods of a class in C# even if syntactically...

Why should you use properties within the methods of a class in C# even if syntactically you don’t have to ?

0 0
Add a comment Improve this question Transcribed image text
Answer #1

In general, methods represent actions and properties represent data. Properties are meant to be used like fields, meaning that properties should not be computationally complex or produce side effects. When it does not violate the following guidelines, consider using a property, rather than a method, because less experienced developers find properties easier to use.That way use properties.

Add a comment
Know the answer?
Add Answer to:
Why should you use properties within the methods of a class in C# even if syntactically...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT