Get random list item android
<p>I want to get a random list item from a list on click of button in android. Can someone guide me to a tutorial or example where I can find how this can be done, or if someone has already done something like this can i see a sample code. I'm clueless as how to get by it. Need help.</p>

<pre><code>public class RandomActivity extends Activity {
String arr[]={"A","B","C","D","E"};
</code></pre>

<p>ListView list;
    p v onCreate(Bundle saved) {</p>

<pre><code>list = (ListView)findViewById(R.id.listView1);
ArrayAdapter&lt;String&gt; adapter = new ArrayAdapter&lt;String&gt;           (this,android.R.layout.simple_list_item_1,arr);
list.setAdapter(adapter);
</code></pre>

<p>}</p>

<pre><code>public void onRandom(View v){
    list.getAdapter().getItem(new Random().nextInt(list.getCount()));
    }
</code></pre>

<p>}
Still not getting the size() method so i substitutedit with getCount().But not generating a random value;</p>
