I know, I know. It’s been a while, and my signature percentage progress hasn’t gone anywhere. It’ll take a ~5 percent jump soon enough.
I will finish it by the end of this week. Now, whether or not this gives me the time to pack in the final large secret I want [...]
Archive for the 'Basic' Category
Decimal to Binary!
January 25, 2007Yes, in one line you can convert any size decimal to binary.
seq(int(2fPart(N/2^Z)),Z,B,1,-1t
N is the number to be converted, while B is the number of bits.
A small math prog…
January 13, 2007Here’s a small program that will find all whole factors of a number. The bigger the number, the longer it takes, though…
:ClrHome
:Repeat Z and Z≤999 not(fPart(Z
:Input “Number? “,Z
:End
:ClrHome
:Output(8,1,”Calculating…
elVar L1Z→dim(L1
elVar L2Ans→dim(L2
:For(θ,1,Z
:Z/θ
:If not(fPart(Ans
:Then
:Ans→L1(θ
:θ→L2(θ
:End
:End
:If not(max(L1
:Then
:ClrHome
isp “It’s prime!
:Stop
:End
:Output(1,1,Z
:Output(2,1,”divided by
:Output(4,1,”is
:For(θ,1,Z
:”
:Output(3,1,Ans
:Output(5,1,Ans
:Output(8,1,”Calculating
:If L2(θ
:Then
:Output(3,1,L2(θ
:Output(5,1,L1(θ
:Output(8,1,”Press Enter
ause
:End
:End
:ClrHome
elVar L1DelVar L2Output(1,1,”
Obviously there are some optimizations, but [...]