title: Sliding window algorithm in C#
body: <p>I'm trying to implement simple sliding window alogirithm on two-dimensional array in C# 3.0, 
  I found <a href="http://distilledb.com/blog/archives/date/2009/03/12/enumerable-extension-method-for-contiguous-subsequences.page" rel="nofollow noreferrer">this</a> as very useful but it involves only single-dimensioal array. </p>
  
  <p><a href="http://distilledb.com/blog/archives/date/2009/03/12/enumerable-extension-method-for-contiguous-subsequences.page" rel="nofollow noreferrer">The post</a> also includes the code for the algo, I'm totaly failed to use it for my senario... can any one suggest me how do I proceed?</p>
  
  <p>Scenario:</p>
  
  <p><a href="https://i.stack.imgur.com/cHSck.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cHSck.jpg" alt="http://parasu516.googlepages.com/matrix.jpg"></a><br>
  <sub>(source: <a href="http://parasu516.googlepages.com/matrix.jpg" rel="nofollow noreferrer">googlepages.com</a>)</sub>  </p>
  
  <p>The above image is 10X10 matrix and need get 3X3 matrix out it, using any algorithm (Sliding window would be greate). Red rectangle is a first set and green one is the second. and it goes on till the end for all rows</p>
  
  <p>PS: I googled about the algo, but no luck :(</p>