title: Champagne Pyramid Distribution Puzzle
body: <p>I recently interviewed with Microsoft and they asked me the following puzzle, for which I had to write an algorithm and accompanying test cases. I wasn't able to crack it and it still is a puzzle to me.</p>
  
  <p>Problem Statement :</p>
  
  <p>A champagne pyramid is a pyramid made of champagne glasses , each of equal capacity say , n.
  The pyramid begins with one glass at the top level , two glasses at the second level , then three below that and so on up to infinite levels. A level x of the pyramid thus has x no. of champagne glasses.</p>
  
  <p>A steady stream of champagne is poured down from the top level,which trickles down to the lower levels. What is the distribution of champagne in the glasses at a given level i.</p>
  
  <p>The problem is quite abstract and those are all the inputs I was given. </p>