The last bands in 4/5 th bands resistors shows the tolerance value of the resistor.The next 2nd digit is ‘ 2 ‘, ∴ look for color in a chart with value 2, then it’s your 2nd color (say red). Next 3rd digit ‘100’ (but value 10^2 = 100) is multiplier ‘ 2 ‘, ∴ look for color in a chart with value 2, thenit’s your 3rd color band (say red). Thus, for 2.2k ohm resistor, 1st digit is ‘ 2 ‘, ∴ look for color in a chart with value 2, then it’s your 1st color(say red).
#22k resistor color code code
∴ the real value of 2.2k ohm resistor is between 2090 Ω to 2310 Ωĭescription: From the resistor color code table we need to find the color code of resistor with respect to its decimal value of the each band counted from left to right. Print(decode_resistor_colors('brown brown green gold'), '1.2.2k ohm resistor color code for 4-band is calculated as: Print(decode_resistor_colors("brown black green silver"), "1M ohms, 10%") Print(decode_resistor_colors('yellow violet yellow gold'), '470k ohms, 20%') Print(decode_resistor_colors("green blue orange"), '56k ohms, 20%') Print(decode_resistor_colors("white blue red gold"), '9.6k ohms, 5%') Print(decode_resistor_colors("yellow violet red gold"), '4.7k ohms, 5%') Print(decode_resistor_colors('yellow white red silver'), '4.9k ohms, 10%') Print(decode_resistor_colors('red yellow red silver'), '2.4k ohms, 5%') Print(decode_resistor_colors('orange orange yellow gold'), '330k ohms, 5%') Print(decode_resistor_colors('brown black yellow gold'), '100k ohms, 5%') Print(decode_resistor_colors('yellow violet orange gold'), '47k ohms, 20%') Print(decode_resistor_colors('brown black orange'), '10k ohms, 20%') Print(decode_resistor_colors('brown black red silver'), '1k ohms, 10%') Print(decode_resistor_colors('blue gray brown'), '680 ohms, 20%') Print(decode_resistor_colors('yellow violet brown silver'), '470 ohms, 10%') Print(decode_resistor_colors('orange orange brown gold'), '330 ohms, 5%') Print(decode_resistor_colors('red red brown'), '220 ohms, 20%') Print(decode_resistor_colors('brown black brown gold'), '100 ohms, 5%') Print(decode_resistor_colors('brown black black silver'), '10 ohms, 10%') Ohm_value = int(str(bands_zero) + str(bands_one)) Res = bands_1_0(bands_1, bands_0)*multiplier Ohm, multiplier, unit = '', '', ' ohms, ' "orange orange yellow gold" "330k ohms, 5%" "brown black yellow gold" "100k ohms, 5%" "yellow violet orange gold" "47k ohms, 5%" "yellow violet brown silver" "470 ohms, 10%" "orange orange brown gold" "330 ohms, 5%"
![22k resistor color code 22k resistor color code](https://projectpoint.in/image/cache/catalog/CFR-1W-22K-1280x720.jpg)
![22k resistor color code 22k resistor color code](https://i0.wp.com/www.thesolderingstation.com/wp-content/uploads/2017/11/Resistor-Color-Chart.jpg)
More examples, featuring some common resistor values Test case resistor values will all be between 10 ohms and 990M ohms. For example, for a resistor with bands of "brown black green silver", you would return "1M ohms, 10%" For example, for a resistor with bands of "yellow violet red gold", you would return "4.7k ohms, 5%"įor resistors of 1000000 ohms or greater, you will divide the ohms value by 1000000 and have an upper-case "M" after it. For example, for the "yellow violet black" resistor mentioned above, you would return "47 ohms, 20%".įor resistors greater than or equal to 1000 ohms, but less than 1000000 ohms, you will use the same format as above, except that the ohms value will be divided by 1000 and have a lower-case "k" after it. The way the ohms value needs to be formatted in the string you return depends on the magnitude of the value:įor resistors less than 1000 ohms, return a string containing the number of ohms, a space, the word "ohms" followed by a comma and a space, the tolerance value (5, 10, or 20), and a percent sign. (There are also more specialized resistors which can have more bands and additional meanings for some of the colors, but this kata will not cover them.) Resistors that do not have a fourth band are rated at 20% tolerance.
![22k resistor color code 22k resistor color code](https://www.speedytemplate.com/resistor-color-code-chart-3_000002.png)
#22k resistor color code plus
Most resistors will also have a fourth band that is either gold or silver, with gold indicating plus or minus 5% tolerance, and silver indicating 10% tolerance. You can see this Wikipedia page for a colorful chart, but the basic resistor color codes are:īlack: 0, brown: 1, red: 2, orange: 3, yellow: 4, green: 5, blue: 6, violet: 7, gray: 8, white: 9Įach resistor will have at least three bands, with the first and second bands indicating the first two digits of the ohms value, and the third indicating the power of ten to multiply them by, for example a resistor with the three bands "yellow violet black" would be 47 * 10^0 ohms, or 47 ohms. While you could always get a tattoo like Jimmie Rodgers to help you remember the resistor color codes, in the meantime, you can write a function that will take a string containing a resistor's band colors and return a string identifying the resistor's ohms and tolerance values. Resistors are electrical components marked with colorful stripes/bands to indicate both their resistance value in ohms and how tight a tolerance that value has.