Dec-30-2017, 05:05 AM
I am new to Python. I am trying to have the following function change the values of certain lines depending on if the lines are populated or not. Please assist if you can. Thanks in advance.
CONSENT1 = aps.checkconsent(line[1493:1495])
CONSENT2 = aps.checkconsent(line[1495:1497])
CONSENT3 = aps.checkconsent(line[1497:1499])
CONSENT4 = aps.checkconsent(line[1499:1501])
CONSENT5 = aps.checkconsent(line[1501:1503])
def checkconsent (CF): original_consent = CF var = CF[0:2] var1 = "RY" if CF == "RY" or "RN" or "NY" or "NN": return var else: return var1CONSENT = aps.checkconsent(line[1491:1493])
CONSENT1 = aps.checkconsent(line[1493:1495])
CONSENT2 = aps.checkconsent(line[1495:1497])
CONSENT3 = aps.checkconsent(line[1497:1499])
CONSENT4 = aps.checkconsent(line[1499:1501])
CONSENT5 = aps.checkconsent(line[1501:1503])