How does fasting work?

So like how does fasting work (what's the purpose?) and what are the rules with it? 

0
0