My python code has suddenly started to give me error. Please see code below**
Gary Herron
gherron at digipen.edu
Tue Oct 9 02:14:16 EDT 2018
So, tell us the error and we'll see what we can do. Give us something
to work with: Cut and past the full error message, trace back,
whatever you can.
Also tell us what version of Python, what system you are running on, how
you run this code, ...
On 10/08/2018 10:17 PM, upadhyay.kamayani at gmail.com wrote:
> ## Calculating the Lower Limits(LLi) and Upper Limit(ULi) for each Band, where i is 1,2,.....10
> LL1=0
> print(LL1)
>
> print(P2)
> print(D2)
>
> if(P2>25):
> UL1=D1
> print(UL1)
>
> elif(UL1==D2):
> print(UL1)
>
> LL2=UL1
>
> if(P3>25):
> UL2=D2
> print(UL2)
>
> elif(UL2==D3):
> print(UL2)
>
> LL3=UL2
>
> if(P4>25):
> UL3=D3
> print(UL3)
>
> elif(UL3==D4):
> print(UL3)
>
>
> LL4=UL3
>
> if(P5>25):
> UL4=D4
> print(UL4)
>
> elif(UL4==D5):
> print(UL4)
>
> LL5=UL4
>
> if(P6>25):
> UL5=D5
> print(UL5)
>
> elif(UL5==D6):
> print(UL5)
>
> LL6=UL5
>
> if(P7>25):
> UL6=D6
> print(UL6)
>
> elif(UL6==D7):
> print(UL6)
>
> LL7=UL6
>
> if(P8>25):
> UL7=D7
> print(UL7)
>
> elif(UL7==D8):
> print(UL7)
>
> LL8=UL7
>
> if(P9>25):
> UL8=D8
> print(UL8)
>
> elif(UL8==D9):
> print(UL8)
>
> LL9=UL8
>
> if(P10>25):
> UL9=D9
> print(UL9)
>
> elif(UL9==D10):
> print(UL9)
>
> LL10=UL9
> UL10=("& Above")
>
> print(UL10)
>
>
>
> **
> n1=int(UL1)
> count=0
> while (n1>0):
> count=count+1
> n1=n1//10
>
> print(count)
>
> B11=LL1
> If((count)/2)==0:
> B12=int((UL1)/(10**(count-2)))
> B12
> elif(B12=int((UL1)/(10**(count-1)))):
> B12
> B1=(B11,"-",B12,"M")
> B1
--
Dr. Gary Herron
Professor of Computer Science
DigiPen Institute of Technology
(425) 895-4418
More information about the Python-list
mailing list