How can we translate the below python function to javascript? Thanks.
def coloring(a): #takes an integer number, returns rgb color
a = a % 255
akM = a // 43
ypD = a % 43
if akM == 0: color = (255, ypD*255/43, 0)
elif akM == 1: color = (255-ypD*255/43, 255, 0)
elif akM == 2: color = (0, 255, ypD*255/43)
elif akM == 3: color = (0, 255-ypD*255/43, 255)
elif akM == 4: color = (ypD*255/43, 0, 255)
elif akM == 5: color = (255, 0, 255-ypD*255/43)
return color
I tried the basics, but no solution.