Question: python!!! what does this line mean especially else 1? doubles += 0 if fdie != sdie else 1 counter[total] += 1 as far as i

python!!! what does this line mean especially "else 1"?

doubles += 0 if fdie != sdie else 1 counter[total] += 1

as far as i understand it's suppose to be an alternative to:

if (fdie != sdie)

doubles+=0

else:

counter[total] += 1

but this isn't working is there an alternative way to write that line that works

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!