Q:

Screen Flash with colored strobe

I want to create a colored strobe effect on the screen using the below code but it didn't work. It's changed the screen color only one time.
int[] colorArray = new int[]{R.color.blue, R.color.purple, R.color.brown, R.color.red, R.color.green, R.color.valvet
        , R.color.darkBlue, R.color.yellow, R.color.litegreen, R.color.orange, R.color.pink, R.color.pgreen,
        R.color.liteBlue, R.color.divider, R.color.icons, R.color.colorAccent, R.color.colorPrimaryDark};

  final Handler handler = new Handler() {
                final Runnable runnable = new Runnable() {
                int i=0;
                public void run() {
                    multi_disco.setBackgroundColor(colorArray[i]);
                    i++;
                    if(i>colorArray.length-1)
                    {
                        i=0;
                    }
                    handler.postDelayed(this, 50);
                }
            };
            handler.postDelayed(this, 2000)};

A:

The flashlight from smartphones can't be colored just because the flash is created for the camera, and in 99,99% of the smartphones is just white.
So, what you are asking, cannot be done.

