|
-
August 18th, 2009, 01:13 AM
#25
Re: Learning C#
Hi all, who can help me with this question??
which of the following is not unboxing conversion?
a. void func1(object o)
{
int i = (int)o;
}
b. void func1(ValueType v)
{
int i = (int)v;
}
c. enum En {e1, e2}
void func1(System.Enum et)
{
En e = (En) et;
}
d. interface I {int Value {get; set;}}
void func1(I vt)
{
int i = vt.Value;
}
e. class C { public int Value {get; set;}}
void func1(C vt)
{
int i = vt.Value;
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|