Shared Hosting is the most common and certainly the least expensive way to host your site. Its most suited for small business and personal web sites. The "shared" part means that there are more number of people / web sites on same server. It does not mean that your files are not secure. Each of the customers on shared hosting gets share of the server as per web hosting package and the files are accordingly placed in a directory to which only the owner has access.
Dedicated web hosting means that an entire computer, commonly called a "server" in the hosting world, is dedicated to hosting your files on the web. You get all the hard drive space, you get to have whatever software you want on it. This is more suited for larger web sites which consume more server resources.
Dedicated web hosting servers are comparatively expensive than shared hosting because you are leasing an entire computer for a certain duration of time. You pay for the cost of the server