Arduino clock needed to print the time a button is pressed while continuing to count the time?
Since you will have to deal with two different times, I suggest
writing a small class for representing those times in broken-down form.
This is a reduced version of the classical strcut tm. Times are made
Printable so you can just print() them to the LCD. I included an
increment() method to add one second to this time.



class BrokenDownTime : public Printable {
    uint8_t hours;
    uint8_t minutes;
    uint8_t seconds;
public:
    void increment();
    size_t printTo(Print &amp;p) const;
};

/* Increment the time by one second. */
void BrokenDownTime::increment()
{
    if (++seconds &gt;= 60) {
        seconds = 0;
        if (++minutes &gt;= 60) {
            minutes = 0;
            if (++hours &gt;= 24)
                hours = 0;
        }
    }
}

/*
 * Print to anything that inherits from the Print class (Serial,
 * LiquidCrystal, etc.). This makes times `Printable'.
 */
size_t BrokenDownTime::printTo(Print &amp;p) const
{
    p.print(hours/10);
    p.print(hours%10);
    p.write(':');
    p.print(minutes/10);
    p.print(minutes%10);
    p.write(':');
    p.print(seconds/10);
    p.print(seconds%10);
    return 8;  // 8 bytes written
}


The main program checks in loop() for the button being pressed. When
this happens, it saves the current time as lastPress. If the button
was ever pressed (variable button_was_pressed), the recorded time is
displayed on the first line:

#include &lt;LiquidCrystal.h&gt;

#define BUTTON_ADC_PIN A0

LiquidCrystal lcd(8, 9, 4, 5, 6, 7);
BrokenDownTime now;

/* Detect a press on `left', change the thresholds for other buttons. */
bool buttonPressed()
{
    int reading = analogRead(BUTTON_ADC_PIN);
    return reading &gt; 405 &amp;&amp; reading &lt; 605;
}

/* Update `now'. */
void updateTime()
{
    static unsigned long last;
    if (millis() - last &gt;= 1000) {
        now.increment();
        last += 1000;
    }
}

void setup()
{
    lcd.begin(16, 2);
}

void loop()
{
    static BrokenDownTime lastPress;
    static bool button_was_pressed;

    updateTime();

    /* Record the time of the button press. */
    if (buttonPressed()) {
        lastPress = now;
        button_was_pressed = true;
    }

    /* Display the recorded time on the first line. */
    if (button_was_pressed) {
        lcd.setCursor(0, 0);
        lcd.print(lastPress);
    }

    /* Display the current time on the second line. */
    lcd.setCursor(0, 1);
    lcd.print(now);
}


I did not test the program, but I hope you get the idea.