×

C# Tutorial

Basics of .Net

C# Basics

C# Fundamentals

C# Operators

C# Loops

C# Type Conversions

C# Exception Handling

C# String Class

C# Arrays

C# List

C# Stack

C# Queue

C# Collections

C# Character Class

C# Class and Object

C# Namespaces

C# Delegates

C# Constructors

C# Inheritance

C# Operator Overloading

C# Structures

C# File Handling

C# Convert.ToInt32()

C# Int32 (int) Struct

C# DateTime Class

C# Uri Class

C# Database Connectivity

C# Windows

C# Other Topics

C# Q & A

C# Programs

C# Find O/P

C# Properties Aptitude Questions and Answers | Set 1

C# Properties Aptitude Questions | Set 1: This section contains aptitude questions and answers on C# Properties.
Submitted by Nidhi, on April 10, 2020

1) There are following statements are given below, which of them are correct about properties in C#.NET?
  1. Normally, properties are used to set and get values in private members of the class.
  2. Properties cannot be overloaded.
  3. Properties can be overloaded.
  4. In the new version on C#.NET, properties are not supported.

Options:

  1. Only A
  2. Only C
  3. B and D
  4. A and C

2) Is it true, we can only create read-only properties in C#.NET?
  1. True
  2. False

3) What is the keyword is used to create read property in C#.NET?
  1. read
  2. getProp
  3. get
  4. readProp

4) What is the keyword is used to create write property in C#.NET?
  1. write
  2. put
  3. save
  4. set

5) There are following statements are given below, which of them are correct about properties in C#.NET?
  1. A property can be read and write simultaneously.
  2. A property can be either read or write-only.
  3. To create a write-only property we should use only to get accessor.
  4. To create a write-only property we should use only set accessor.

Options:

  1. Only A
  2. Only B
  3. A and D
  4. B and C



Advertisement
Advertisement


Comments and Discussions!

Load comments ↻


Advertisement
Advertisement
Advertisement

Copyright © 2025 www.includehelp.com. All rights reserved.