变量的语法
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace shan_ma_wang01
{
internal class Program
{
static void Main(string[] args)
{
//变量的语法
//数据类型 变量名;1.声明变量
int score;
//数据类型 变量名 = 值;
int lifeValue = 3;
//变量名 = 值; =:2.赋值变量.
score = 17;
//3.使用变量
Console.WriteLine(score);
Console.WriteLine(lifeValue);
Console.ReadKey();
//命名规则
//必须以字母 _ 或者@符号开头,不能以数字开头
//_ @暂时不要用,它们有自己的特殊意义
}
}
}