int led = 11;
void setup()
{
  Serial.begin(9600);
  pinMode(led,OUTPUT);     
}

void loop()
{
  int x,z;
  x = analogRead(A0);
  z = map(x,0,1023,100,800);
  Serial.print("x = ");Serial.println(x);
  Serial.print("z = ");Serial.println(z); 
  delay(1000);
  digitalWrite(led,HIGH);
  delay(z);
  digitalWrite(led,LOW);
  delay(z);
}

