+ 2
Output problem
how to get output of these line b=('float( (i-x) *2 +(j-y) *10 +(k-a) *5)') print (b) i have mentioned the value of i j k x y a... but how to get output in integer.. plz tell me the statement... when i run these it is writing add it is... but not the the answer... i want to do calculation with these kind.... plz help
12 Answers
+ 2
ohk i will try... wait 2 min.
+ 2
star lord plz help me
+ 2
thanks star lord it worked
+ 1
ohh no it is not working. plz help
+ 1
shall i post my whole output
+ 1
i=input('no. of orange candy taken')
print(i)
j=input('no. of chocobar candy')
print(j)
k=input('no. of vanila candy')
print(k)
l=input('no. of cups taken')
print(l)
x=input('no. of remaining orange')
print(x)
y=input('no. of remaining chocobar')
print(y)
a=input('no. of remaining vanilla')
print(a)
z=input('no. of remaining cup')
print(z)
print('total :-')
b=float( (i-x) *2 +(j-y) *10 +(k-a) *5)
print (b)
print('benifit')
c=float(b*(30/100))
print(c)
print('we have to take:-')
print(b-c)
+ 1
u copy and paste and make input as 10,10,10,10 ,3,3,3,3
+ 1
ohh thanks i will try it