[Python] Resister Color Expert. One band can only have one color?

The Resistor Color Expert exercise says,

  • orange-orange-orange-black-green would be 330 ohms with a ±0.5% tolerance.
    There are also one band resistors. This type of resistor only has the color black and has a value of 0.
  1. Is the “one band resistors” note supposed to be part of the “orange-orange-orange-black-green” example?
  2. This “only has the color black” implies when there is exactly one color, you can ignore the color and just return "0 ohms". Is that correct/intentional?
  1. I don’t think so, should be a separate note
  2. No, only if black.

@Meatball whom I think wrote this

I don’t agree it implies what you said it implies, so for me the only issue is that formatting thing.

I have been on vacation hence the reason for the delayed response.

  1. I think those are supposed to be separated, yes.
  2. Yes it is only zero ohms as DJ said (and as they said so do that for me seem fine to me as well), Zero-ohm link - Wikipedia.

There is a PR fix here: [Resistor Color Expert]: Corrected Small Typos by BethanyG · Pull Request #3469 · exercism/python · GitHub, but currently the CI is broken, so I need to fix that first.

1 Like