|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: collapsing number ranges
> Is there some easy way -- in XSLT 2.0 -- to handle in a general way > collapsing number ranges like: > > 23-24 => 23-4 > 333-334 => 333-34 > 7777-7778 => 7777-78 > I can't tell from these three examples what your algorithm is. If the second number were to contain all trailing digits that differ from those of the first number, then it's doable - but I don't think there's an "easy way" even then. You just have to work through the second string outputting each digit only if the substring up to and including that digit differs from the leading substring of the same length in the other number - which can probably be done in 1.0 as easily as in 2.0. Michael Kay
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








