using System;
public class TestNumSort
{
public static void Main()
{
int a, b, c, d;
for (a=1; a<=4; a++)
for (b=1; b<=4;b++ )
for (c=1;c<=4;c++)
if (a!=b&&a!=c&&b!=c)//abc互不相等
{
d=10-a-b-c;
if ((c==1^b==2) && (c==2^d==3) && (a==2^d==4))//甲乙丙都有一半是正确的
{
Console.Write("红球放置在{0}号,黄球放置在{1}号,", a, b);
Console.WriteLine("黑球放置在{0}号,白球放置在{1}号,", c, d);
}
}
Console.Read();
}
}
using System;
public class TestNumSort
{
public static void Main()
{
int a=1, b=1, c=1, d;
while (a<=4)
{
while (b<=4)
{
while (c<=4)
{
if (a!=b)