# Color Translator

Hello, my last post was marked as spam which was pretty rude.

I am working hard on developing my own software and I am new to coding. for a class project I am to create a calculator similar to a tutorial for making a student grade point average calculator. I decided to instead use the code to make a translator for color hex + rgb numbers. it looks like this so far:

``````_author_ ='Melissa'

# Input List: color\_name
# Output List: color\_rgb, color\_hex

# Function Char, String get\_color\_name()
# Declare Char color\_name
#
# Display "Please enter the color name:"
# Input color\_name
# Return color\_name
# End Function

def get_color_name():
color\_name=""

color_name = char(input("Please enter the color name:"))
return color_name

# Function String convert\_color\_number(Char color\_name)
# Declare String color\_rgb
# Declare String color\_hex
#
# If color\_name == "Pink" Then
# color\_rgb = "(255, 192, 203)"
# color\_hex = " #ffc0cb"
# Else If color\_name == "Blue" Then
# color\_rgb = "(0, 0, 255)"
# color\_hex = " #0000ff"
# If color\_name == "Green" Then
# color\_rgb = "(0, 128, 0)"
# color\_hex = " #008000"
# If color\_name == "Yellow" Then
# color\_rgb = "(255, 255, 0)"
# color\_hex = " #ffff00"
# If color\_name == "Red" Then
# color\_rgb = "(255, 0, 0)"
# color\_hex = " #ff0000"
# If color\_name == "Orange" Then
# color\_rgb = "(255, 165, 0)"
# color\_hex = " #ffa500"
# If color\_name == "Purple" Then
# color\_rgb = "(128, 0, 128)"
# color\_hex = " #800080"
# If color\_name == "Black" Then
# color\_rgb = "(0, 0, 0)"
# color\_hex = " #000000"
# If color\_name == "White" Then
# color\_rgb = "(255, 255, 255)"
# color\_hex = " #ffffff"
# If color\_name == "Gray" Then
# color\_rgb = "(128, 128, 128)"
# color\_hex = " #808080"
# If color\_name == "Brown" Then
# color\_rgb = "(165, 42, 42)"
# color\_hex = " #a52a2a"
# End If
# Return color\_rgb, color\_hex
#End Function
``````