no colons separating statements (use new line number)
assume THEN and END IF not optional, that sort of thing.
int a=10000,b,c=2800,d,e,f[2801],g;main(){for(;b-c;)f[b++]=a/5; for(;d=0,g=c*2;c-=14,printf("%.4d",e+d/a),e=d%a)for(b=c;d+=f[b]*a,f[b]=d%--g,d/=g--,--b;d*=b);}
Long shot and quite off topic (apologies): I've been looking for a few years for a BASIC program to calculate Pi on a PDP, ideally TSS/8. I spent a lot of time googling and trying to get Apple and other BASIC programs to work on the PDP... but mostly the Pi program are on more modern versions so don't easily downgrade to the simple PDP8 BASIC. I remember copying a BASIC program from a computer magazine in the 1980s which ran with little modification on a PDP-10 BASIC... but no luck tracking that down :-)
Any thoughts?
cheers!
Andy
--
You received this message because you are subscribed to a topic in the Google Groups "PiDP-8" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pidp-8/q4eEMXGPRa0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pidp-8+un...@googlegroups.com.
To post to this group, send email to pid...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pidp-8/CAMPG4Y9uMeACcwhgwYKv2Pxa4EcmNBY8ut9NAL6y%2BVHGRAYncg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
.R TECO
*i100$$
*GZ0J\UNQN"E 40UN ' BUH BUV HK
QN< J BUQ QN*10/3UI
QI< \+2*10+(QQ*QI)UA B L K QI*2-1UJ QA/QJUQ
QA-(QQ*QJ)-2\ 10@I// -1%I >
QQ/10UT QH+QT+48UW QW-58"E 48UW %V ' QV"N QV^T ' QWUV QQ-(QT*10)UH >
QV^T @^A/
/HKEX$$
3141592653589793238462643383279502884096548392828580051774206964461331476026438773944051683122394366
I don't recall where I found this, but if you want obscure you can try this. It's supposed to be a TECO macro for calculating pi:.R TECO
*i100$$
*GZ0J\UNQN"E 40UN ' BUH BUV HK
I don't recall where I found this, but if you want obscure you can try this. It's supposed to be a TECO macro for calculating pi:
.R TECO
*i100$$
*GZ0J\UNQN"E 40UN ' BUH BUV HK
QN< J BUQ QN*10/3UI
QI< \+2*10+(QQ*QI)UA B L K QI*2-1UJ QA/QJUQ
QA-(QQ*QJ)-2\ 10@I// -1%I >
QQ/10UT QH+QT+48UW QW-58"E 48UW %V ' QV"N QV^T ' QWUV QQ-(QT*10)UH >
QV^T @^A/
/HKEX$$
3141592653589793238462643383279502884096548392828580051774206964461331476026438773944051683122394366
The $s are <esc>. The last line is TECO output, not user input.Have fun. . . :^)
--
You received this message because you are subscribed to a topic in the Google Groups "PiDP-8" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pidp-8/q4eEMXGPRa0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pidp-8+un...@googlegroups.com.
To post to this group, send email to pid...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pidp-8/9b3db5dd-47c1-42ad-ba27-3b1bb3d03631%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "PiDP-8" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pidp-8+un...@googlegroups.com.
To post to this group, send email to pid...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pidp-8/9b3db5dd-47c1-42ad-ba27-3b1bb3d03631%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
I'm quite sure that this macro is the work of Stanley Rabinowitz.
You received this message because you are subscribed to a topic in the Google Groups "PiDP-8" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pidp-8/q4eEMXGPRa0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pidp-8+un...@googlegroups.com.
To post to this group, send email to pid...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pidp-8/CAPdDV0j%2B1cXHsr21zoy2ScMs8MVEZMsyYvec_rAK522dx0KaQw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.