8-|  <== this is my "staring look"

Nope, I cannot see it, the difference is 30, sooo?

Ohhhhhhhhhhhhhhhhh, it is a date thing!

differences are 31,29,31,30,31,30,.....  and it blows on "13,1"

lets do a program...

<cfoutput>
<cfloop INDEX="i" FROM="1" TO="24">
  <cfset j = i + 1>
  <cfset d1= i&",1">
  <cfset d2= j&",1">
  <cfset nf=NumberFormat("#d1#")>
  <cfset nf2=NumberFormat("#d2#")>
  <cfset diff=ListGetAt(nf2,2) - ListGetAt(nf,2)>
  #d1#==>#nf# &nbsp;(#diff#)<br>
</CFLOOP>
</CFOUTPUT>

gives

1,1==>36,526  (31)
2,1==>36,557  (29)
3,1==>36,586  (31)
4,1==>36,617  (30)
5,1==>36,647  (31)
6,1==>36,678  (30)
7,1==>36,708  (31)
8,1==>36,739  (31)
9,1==>36,770  (30)
10,1==>36,800  (31)
11,1==>36,831  (30)
12,1==>36,861  (-323)
13,1==>36,538  (1)
14,1==>36,539  (1)
15,1==>36,540  (1)
16,1==>36,541  (1)
17,1==>36,542  (1)
18,1==>36,543  (1)
19,1==>36,544  (1)
20,1==>36,545  (1)
21,1==>36,546  (1)
22,1==>36,547  (1)
23,1==>36,548  (1)
24,1==>36,549  (1)

Nice bug!  You can know now how many days in a month, on a leap year, except
for december.

What was on the developer's head?

<Jaime/>



> -----Original Message-----
> From: Dan Haley [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, October 05, 2000 9:18 AM
> To: CF-Talk
> Subject: RE: NOT A MATH QUESTION, NumberFormat
>
>
> Ahhh, I know what it is. :)
>
> Take a look at the differences between 4,1 and 5,1.  Remind you
> of anything?
>
> Great way to start the morning - get the brain juices flowing again!
>
> Dan
>
> -----Original Message-----
> From: Jaime Garza [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, October 04, 2000 5:28 PM
> To: CF-Talk
> Subject: RE: NOT A MATH QUESTION, NumberFormat
>
>
> Not so fast
>
> Hex 0x4000 => 16384.
> Octal 4000 2048.
>
> 36617 in bin => 1000111100001001 which does not look at all like a 4000 in
> any numerical system.
>
> With more tests, 4,000, 4,00 4,0 and 4, return the same number.
> But 3,0 returns 36586
> And 2,0 returns 36557
> And 1,0 returns 36526
>
> 36,617 - 36586 = 31
> 36586 - 36557 = 29
> 36557 - 36526 =  31
>
>
> And it does not take "0,0"
>
> So there is no pattern...  Interesting bug.  Random is not.
>
> <Jaime/>
>
>
>
> > -----Original Message-----
> ------------------------------------------------------------------
> ------------
> Archives: http://www.mail-archive.com/[email protected]/
> To Unsubscribe visit
> http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf
_talk or send a message to [EMAIL PROTECTED] with
'unsubscribe' in the body.

------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to