Problems with unity 5

After upgrading to unity 5 and to the new api, a problem started to occur.
This message started to appear “IndexOutOfRangeException: Array index out of Range” pointing to this part of the code
int rand0 = Random.Range(0,51); GameObject.Find("/Player 0/Cad 0").GetComponent<SpriteRenderer>().sprite = cartas[rand0];
Any suggestions ?

solve the problem, while upgrading to unity 5, unity deleted the resources folder and I didnt notice