dimanche 24 juin 2018

How to withdraw unique images?

How to withdraw unique images?

int[] resimler ={R.drawable.yesil,R.drawable.mavi,R.drawable.kare,R.drawable.soru};

    int[] secilen=new int[resimler.length];

    for (int i=0;i<resimler.length;++i) {


        int resim=resimler[new Random().nextInt(resimler.length)];

        secilen[i]=resim;


    }



    img1.setImageResource(secilen[0]);
    img2.setImageResource(secilen[1]);
    img3.setImageResource(secilen[2]);
    img4.setImageResource(secilen[3]);




Aucun commentaire:

Enregistrer un commentaire