jeudi 6 avril 2017

How to get a Random Colour in an array in java

I'm creating a program which generates a random car with a random price, year, colour, etc... I know how to randomize the year by using Math.random, but I'm not sure how to get a random colour. I think making an array full of colours and picking a random element from the array, but I'm not sure how to do that. Any help is greatly appreciated




Aucun commentaire:

Enregistrer un commentaire