【发布时间】:2013-02-13 15:56:10
【问题描述】:
谁能告诉我如何使用stack.ofType<>?我试了很多次都做不到。
private void button2_Click(object sender, EventArgs e)
{
Stack st = new Stack();
st.Push("joginder");
st.Push("singh");
st.Push("banger");
st.Push("Kaithal");
st.OfType<> //how to work this option
}
【问题讨论】:
-
不清楚,你要做什么。
-
您只是在堆栈中插入字符串,因此
OfType<>()给您带来的好处尚不清楚。你能详细说明你想要达到的目标吗?