Skip to content

Commit b2f91d3

Browse files
committed
1 parent 3aa17cb commit b2f91d3

File tree

3 files changed

+18
-0
lines changed

3 files changed

+18
-0
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import os
2+
3+
def main():
4+
x = int(input())
5+
colors = [input().split("#")[-1] for i in range(x)]
6+
for color in colors:
7+
r, g, b = int(color[:2], base=16), int(color[2:4], base=16), int(color[4:6], base=16)
8+
c = f"#{str(hex(255-r)).replace('0x', '').zfill(2)}{str(hex(255-g)).replace('0x', '').zfill(2)}{str(hex(255-b)).replace('0x', '').zfill(2)}"
9+
print(c.upper())
10+
11+
12+
if __name__ == '__main__':
13+
main()
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<img src="./doc/quiz.png">
2+
3+
4+
5+
https://quera.org/problemset/244098
130 KB
Loading

0 commit comments

Comments
 (0)