Probably it's a good idea to understand digital/analog wave theory first. Have a look here: http://www.mediacollege.com/audio/01/. It's quick and you should pick up on that fairly well. But, just to add onto it:
In the digital world
1) One sample = one frequency, although a sample is NOT the same thing as a frequency. It's just common analog -> digital conversion to use the same number. If you have a 44100HZ audio file, you have 44100 samples per second in your wave.
2) Audio is represented in bytes (duh , meaning an audio sample is typically between -127 and 128. Or if it's a 16bit audio sample, it's between -32767 and 32768, and so on.
3) In order to generate sound, the samples need to have a sinusoidal-like waveform. Meaning if you analyze the bytes in a wave, it will look like a roller coaster ride. It should go up and then down, then back up and so on. As you manipulate those properties, you will generate different sounds. Search up on "synthesizers" to get a better understanding of how this works, including getting a glimpse of a DJ's life
So once you understand the basics, you should know that:
- The number of bytes per second of sound = (samples per second) * (number of channels) * (bytes per sample)
Where by now you should know that samples per second is the same number as frequency. The number of channels would be 1 for mono, 2 for stereo, etc..., and bytes per sample is typically 1, 2, or 3, although people commonly refer to it as bits such as 8, 16, or 24 (but real devs only work in bytes . If you're importing audio from wav, mp3, ogg, etc... they have all this informaton in the headers.
Knowing the above equation should allow you to easily calculate how many bytes of zeros you would need to append to the wave form to add silence. Now you should ask yourself "why do zeros silence the wave? Here's another question you should ask. Could I generate silence by filling it with any value? The answer is yes. You could do a memory copy with 0xFF, 0xA2, 0x24, etc... As long as there is no oscillation, you will not hear any sound. Zeroes are just easier to work with in editors because the 0'th line is in the center of the oscilloscope.
Once you grasp all of this, dealing with sounds (or wave theory in general) is actually simple and fun. Don't think about wave, mp3, ogg, etc... They are just formats. Audio in the end is broken down into 3 simple factors: wavelength, amplitude, and frequency. Play with those and you'll pick up on stuff very quickly. A while back I even wrote a program where the computer tries to make music. heh... funny stuff. Brought a whole new meaning to the word chip-tunes