using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
//流程控制
int i = 1;
if (i > 10)
{
Console.WriteLine("你好");
}
if (i > 2)
{
Console.WriteLine("1大于2");
}
else
{
Console.WriteLine("1不大于2");
}
int age = 19;
if (age > 18)
{
Console.WriteLine("成人");
}
else if (age > 15)
{
Console.WriteLine("少年");
}
else
{
Console.WriteLine("儿童");
}
Console.ReadKey();
}
}
}
本文出自 “Kenan_ITBlog” 博客,请务必保留此出处http://soukenan.blog.51cto.com/5130995/1076215