猜猜看以下程序的输出是什么?
using System;
using System.Windows.Forms;
namespace Skyiv.Ben.Test
{
sealed class MainTest
{
static void Main()
{
Label lblOut = new Label();
lblOut.Text = null;
Console.WriteLine("{0} {1}", lblOut.Text == null, lblOut.Text == "");
}
}
}
lblOut.Text = GetAccount();
if (lblOut.Text == null) lblOut.Text = "无此账号";
结果这个if语句永远不会取真值。



浙公网安备 33010602011771号