Read a freqency from an analog pin

void loop()
{
   long getFrequency(A0);
   { 
     #define SAMPLES 4096 
     long freq = 0; 
     for(unsigned int j=0; j<SAMPLES; j++)
     {
        freq+= 500000/pulseIn(A0, HIGH, 250000);
     } 
     frequency = freq/SAMPLES;
     if (frequency <1)
     {
       digitalWrite(5, HIGH);
       digitalWrite(11,HIGH);
     }
     if (frequency >=1)
     {
       digitalWrite(12, HIGH);
       digitalWrite(15,HIGH);
     }              
  }
}

Without your atrocious indenting, and with curly braces every where, this is your loop function. So, what exactly is the function prototype in the loop() function for? You don't call the function anywhere, nor do you implement it, so get rid of it. Then, the { and } that follow it are useless.

You really don't understand what frequency means, do you?