Here’s a link to an overview of writing a Powershell cmdlet:
http://msdn.microsoft.com/en-us/library/dd878294%28v=vs.85%29.aspx
Basically a true Powershell cmdlet is written in a .NET programming language, typically C#, and compiled – so in a way it’s a real application. An advanced function is written in Powershell (although you could include some custom C# code) and is not compiled. There are probably performance benefits to implementing a compiled cmdlet rather than an advanced function but the functions exist for us average joe admins who aren’t real programmers to be able to develop and share our own tools.
This is probably not the most eloquent description so I’ll leave the nitty-gritty details to those who know more about the developer side of Powershell and .NET.