Smart grains of programmable sand could one day be used to build anything spontaneously.