Re: How short can I make it
Re: How short can I make it
- Subject: Re: How short can I make it
- From: "Mark J. Reed" <email@hidden>
- Date: Thu, 13 Oct 2011 20:41:51 -0400
Yes, well, I did write them in about 5 minutes. :) Never intended to handle fractions or negative numbers, though I should totally have caught the zero case.
Sent from my iPad
On Oct 13, 2011, at 7:28 PM, Stan Cleveland <email@hidden> wrote:
> On Oct 13, 2011, at 3:37 PM, Mark J. Reed wrote:
>
>> These should do the trick:
>>
>> <snip>
>>
>> toString from 1318544445 by 36
>> toNumber from "LT0ZEL" by 36
>
> Hi Mark,
>
> Very nice. Your handlers will get some study here. It looks like there are some edge-case inputs that will need additional handling. Specifically, decimal fractions (0.25 --> "0.25" --> 77), negative values (-4 --> "" --> 0), zeroes (0 --> "" --> 0), and null strings ("" --> "" --> 0).
>
> Nevertheless, your code provides a good starting point and your idea may prove useful for obfuscating and/or shortening numeric data.
>
> Thanks,
> Stan C.
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> AppleScript-Users mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
> Archives: http://lists.apple.com/archives/applescript-users
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden