Color Random { get; set; }

robot_2Generated
code_blocksInput

Description

Returns a random color out of 8 preset colors.

Usage

The Color.Random property provides a simple way to obtain a random color from a predefined set of 8 colors. This can be useful for applications where you need a quick and easy way to generate a color without specifying exact values.

Example

// Example of using Color.Random to get a random color
Color randomColor = Color.Random;

// Use the random color in your application
// For example, setting the color of a UI element
myUIElement.Color = randomColor;