Assign a Javascript Array Colour

Right now I have this javascript for assigning a material colour, randomly, from an array or colours.

var ballColourArray = new Array("white","red","blue","green","yellow","black");

function Start () {

    renderer.material.color = Color.ballColourArray(Random.Range(0,ballColourArray.length)).value;
    }

But this gives an error “ballColourArray is not a member of UnityEngine.color)”.

What have I done wrong please?

Absolutely do not ever use Array. Use a standard built-in Color array. Also, you can’t use strings to indicate colors, you must use Colors.

var ballColors : Color[]; // Assign colors in inspector
// Or:
var ballColors = [Color.white, Color.red, Color.blue, Color.green, Color.yellow];

Finally, you don’t assign colors like that, just assign it directly: renderer.material.color = ballColors[2];