unity change the source image or image

C#
public Image test;
public Sprite example;

void Start()
{
 test.sprite = example; //change the source image of the image "test" to the sprite "example" 
}
Source

Also in C#: