global proc randomSelect()
{
//    global string $pyramidArray[];
    
    string $pyrArray[] = `ls "py****"`; 
    int $Smax = getSliderValueS();
    
    int $arraySize = `size $pyrArray`;
    int $py[];
    
    for($s = 0; $s < $Smax; $s++) 
    {
    
    int $Svalue = `rand $arraySize`;
    $py[$s] =  $Svalue;
    
    }
    int $eachIndex;
    select -clear;
    for($eachIndex in $py)
    {
        select -add $pyrArray[$eachIndex];
    } 
    
}