2D Game Random spawning above the map


I am working on a simple 2D catch game, where you have to catch falling objects. Just for fun and trying to learn a little bit of coding. But now I am stuck with the spawn script. I want my objects to spawn randomly above the map.

Hope if anyone could help me.


public class RandomPosition : MonoBehaviour
void Start ()
Vector3 pos = GetComponent().position;

        pos.x = Random.insideUnitSphere.x * 5;
        pos.z = Random.insideUnitSphere.z * 5;
	    pos.y = // A number that is higher than the top of the screen
	    GetComponent<Transform>().position = pos;