ChipMaster's bwBASIC This also includes history going back to v2.10. *WARN* some binary files might have been corrupted by CRLF.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

caljd.bas 540 B

123456789101112131415161718192021
  1. 800 REM CALENDAR --> JD
  2. 805 REM
  3. 810 INPUT "Y,M,D ";Y,M,D
  4. 815 INPUT "JC (0) OR GC (1) ";G
  5. 820 D1=INT(D): F=D-D1-0.5
  6. 825 J=-INT(7*(INT((M+9)/12)+Y)/4)
  7. 830 IF G=0 THEN 850
  8. 835 S=SGN(M-9): A=ABS(M-9)
  9. 840 J1=INT(Y+S*INT(A/7))
  10. 845 J1=-INT((INT(J1/100)+1)*3/4)
  11. 850 J=J+INT(275*M/9)+D1+G*J1
  12. 855 J=J+1721027+2*G+367*Y
  13. 860 IF F>=0 THEN 870
  14. 865 F=F+1: J=J-1
  15. 870 PRINT "J.D.: ";J;F
  16. 875 END
  17. 880 REM ------------------------
  18. 885 REM APPEARED IN ASTRONOMICAL
  19. 890 REM COMPUTING, SKY & TELE-
  20. 895 REM SCOPE, MAY, 1984
  21. 900 REM ------------------------