The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM



Thread: Few questions
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #2 (permalink)  
Old 05-28-2007
matrixmadhan matrixmadhan is offline
Technorati Master
 

Join Date: Mar 2005
Location: k-tier distributed caching
Posts: 2,736
Take mod of the value which you desire.

for values from 1..x

and if you want reduce the set to 1..y

take mod value for x and y.

Taking mod value with y for value x,

will bring down the set 1..x to 1..y
Reply With Quote