def METHOD_NAME(lst, timestamp):
    if not lst:
        return None
    nearest_ts = min(lst, key=lambda ts: abs(ts - timestamp).total_seconds())
    if abs(nearest_ts - timestamp).total_seconds() < 1:
        return nearest_ts