How to make a variable for scripts?

What I’m trying to find out is how to make a variable pertaining to a script “open” so it can be changed later. Kind of like what you would do for an : int variable. This is just a random example of what I mean:

var archerGilgamesh : int;

Can anyone give me the int version of a variable referencing a script? Is there even one?

var archerGilgamesh : Component;

This lets you choose a script in the inspector?