accessing to one array from another script

Hi all;
I have an array in one script, and I have to access it in another script.
I fill the array in script “A” like this:

@RPC

function IsAvailable()
{

while (count < 13)

{

RandNo = Random.Range(1,13);

for(i=0; i<13; i++)
{

if (RandomCardNO == RandNo)
{
break;
}
else
{
RandomCardNO = RandNo;
count++;
}
}
}
for(i=0; i<13; i++)
IsGained = false;

}
I want to access to the RandomCardNO[] in script"B" (both the server and clients). I try to access it in script “B” in update function.
How can I do it?

If RandomCardNO is declared in script B, and both A and B are attached to the same object, you can do the following in A, to retrieve that:

RandomCardNO_temp = GetComponent(B).RandomCardNO;

My problem is that A and B are attached to the different game objects.