very easy problem...help me

Shader “Example/Diffuse Texture” {
Properties {
_MainTex (“Texture”, 2D) = “white” {}//…Declaration once
}
SubShader {
Tags { “RenderType” = “Opaque” }
CGPROGRAM
#pragma surface surf Lambert
struct Input {
float2 uv_MainTex;
};
sampler2D _MainTex;//…Declared again,why? Declare the same thing twice ,is it a must???
void surf (Input IN, inout SurfaceOutput o) {
o.Albedo = tex2D (_MainTex, IN.uv_MainTex).rgb;

Those two are not equal, the first one declares a property, which is visible when you assign the shader to a material, you can change these values and see the description in the material inspector.

The second declaration is for the shader, so that inside the shader code you can use the previousely declared property. When your shader does not need to access this property you can leave it out and keep the shader smaller and the performance higher.

thank you