Understanding the exposure triangle is one of the first technical points that you need to understand when you get in to photography. Thankfully, in the digital age, we are afforded the opportunity for trial and error.
The three factors that affect exposure are:
Lens Aperture - The amount of light allowed through the lens
Shutter Speed - The amount of time the shutter stays open, the long it is open, the more light is allowed through.
ISO Sensitivity - This controls how the sensitivity to light of the image sensor (this is actually applied gain, like turning the volume up on an audio device, increases the sound, but can also increase background noise, or in the case of an image, it will force an image to be brighter, but there is also more unwanted digital grain (called noise)