Jan-28-2018, 09:03 PM
Thanks guys for the quick replies i'll definitely use this information,
But its also not quite the issue i'm running into. Its that on two occasions when I have programmed something that involves formating a string or a list, it will work on 4 out of the 5 strings but there's one that just ignores it, everything is the same between them but it just doesn't change.
So for example one script I have 6 calculations that each returns a float and I want to round down so I use a round command.
It will work on 5 of them but the last one just returns the same number.
But its also not quite the issue i'm running into. Its that on two occasions when I have programmed something that involves formating a string or a list, it will work on 4 out of the 5 strings but there's one that just ignores it, everything is the same between them but it just doesn't change.
So for example one script I have 6 calculations that each returns a float and I want to round down so I use a round command.
It will work on 5 of them but the last one just returns the same number.
def dms_calc(DMS,DMS_Cost, Cost_Opinion): import math if DMS == "A": A = (0.187547-(0.01836*(math.log10(DMS_Cost/7.76)))) A = round(A,4) print(A*100, "%") print("$",DMS_Cost*A) elif DMS == "B": B = (0.164145-(0.015303*(math.log10(DMS_Cost/7.76)))) B = round(B,4) print(B*100, "%") print("$",DMS_Cost*B) elif DMS == "C": C = (0.142432-(0.010594*(math.log10(DMS_Cost/7.76)))) C = round(C,4) print(C*100, "%") print("$",DMS_Cost*C) elif DMS == "D": D = (0.141419-(0.01236*(math.log10(DMS_Cost/7.76)))) D = round(D,4) print(D*100, "%") print("$",DMS_Cost*D) elif DMS == "E": E = (0.118011-(0.009279*(math.log10(DMS_Cost/7.76)))) E = round(E,4) print(E*100, "%") print("$",DMS_Cost*E) elif DMS == "F": F = (0.09521-(0.006301*(math.log10(DMS_Cost/7.76)))) F = round(F,4) print(F*100, "%") print("$",DMS_Cost*F)and the with the script I was talking about at the start it does the same were it will work on 80% of the lists but it just ignores some of them. It just seems like a bug and was wondering if anyone else had experience with something like this.