I have the following structure:
struct cores
{
int r, g, b;
public cores(int r, int g, int b)
{
this.r = r;
this.g = g;
this.b = b;
}
}
If I have a new structure printed, it looks like this:
Console.WriteLine(new cores(1, 0, 0));
//Saída Program.cores
But I would like the output to be:
Console.WriteLine(new cores(1, 0, 0));
//Saída R: 1 - G: 0 - B: 0
How can I do this?
I know that there are already some similar questions here in the OS, but none of them are specific to the case described, and when I went to look for it, it was very difficult to find, besides the content not being in good state for learning.