Qus:    What is boxing and unboxing?
Dec 11, 2020 21:13 DotNet 2 Answers Views: 1095 RAMU

 



Boxing is used convert value to reference type. For example

Int x =10

Object x = (object) x; //converting the integer to object type.

Object Myclass;

MyClass =87;

Int y = (Int )y;

Prev Next
Answers (2)
PARTH Dec 12, 2020 08:58
Answer:   Converting a value type to a reference type is called called boxing and converting a reference type to a value type is called unboxing.

DIVYA Dec 12, 2020 14:25
Answer:   Boxing is used convert value to reference type. For example
Int x =10
Object x = (object) x; //converting the integer to object type.
Object Myclass;
MyClass =87;
Int y = (Int )y;

Post Your Answer
Guest User

Not sure what solution is right for you?

Choose the right one for you.
Get the help of the experts and find a solution that best suits your needs.


Let`s Connect