The Museum of HP Calculators


Day of Year - Day of Week for the HP-41C/CV/CX

This program is Copyright © HP and is used here by permission. It was originally printed in the Calendars Solution Book. This program was entered and uploaded by Tony Duell.

This program is supplied without representation or warranty of any kind. Tony Duell, Hewlett Packard and The Museum of HP Calculators therefore assume no responsibility and shall have no liability, consequential or otherwise, of any kind arising from the use of this program material or any part thereof.

Documentation Information (CD or source code)
How to get this Program to your Calculator (via HP-IL, disk, wand, and fingers)
Download Binary (.raw) program for disk or PC HP-IL Card download
Download Hexadecimal (.dat) program for Serial Port download

Program Listing

LINE  KEYS
 01 LBL "DOY"
 02 XEQ 08
 03 "MM.DDYYYY ?"
 04 PROMPT
 05 XEQ 00
 06 STO 02
 07 RCL 04
 08 1 E6
 09 /
 10 1
 11 +
 12 XEQ 00
 13 RCL 02
 14 -
 15 CHS
 16 STO 00
 17 CF 29
 18 CLA
 19 ARCL X
 20 SF 29
 21 "|- DAY"
 22 AVIEW
 23 RTN
 24 LBL 00
 25 ENTER
 26 INT
 27 STO 07
 28 -
 29 1 E2
 30 *
 31 ENTER
 32 INT
 33 STO 08
 34 -
 35 1 E4
 36 *
 37 STO 09
 38 STO 04
 39 RCL 07
 40 1
 41 +
 42 ENTER
 43 1/X
 44 .7
 45 +
 46 CHS
 47 XEQ 04
 48 RCL 01
 49 *
 50 INT
 51 RCL 09
 52 RCL 10
 53 *
 54 INT
 55 +
 56 RCL 08
 57 +
 58 RTN
 59 LBL 04
 60 INT
 61 ST+ 09
 62 12
 63 *
 64 -
 65 RTN
 66 LBL "DAT"
 67 XEQ 08
 68 "YEAR ?"
 69 PROMPT
 70 "DOY ?"
 71 PROMPT
 72 STO 00
 73 RDN
 74 STO 04
 75 1 E6
 76 /
 77 1
 78 +
 79 XEQ 00
 80 RCL 00
 81 +
 82 STO 02
 83 RCL 05
 84 -
 85 RCL 10
 86 /
 87 INT
 88 STO 09
 89 RCL 10
 90 *
 91 INT
 92 RCL 02
 93 -
 94 CHS
 95 STO 06
 96 RCL 01
 97 /
 98 INT
 99 STO 07
100 RCL 06
101 X<>Y
102 RCL 01
103 *
104 INT
105 -
106 STO 08
107 RCL 07
108 1
109 RCL 08
110 %
111 -
112 -
113 RCL 07
114 14
115 /
116 XEQ 04
117 CF 29
118 CLA
119 INT
120 ARCL X
121 "|--"
122 LASTX
123 FRC
124 1 E2
125 *
126 ARCL X
127 "|--"
128 ARCL 09
129 AVIEW
130 SF 29
131 CLX
132 RTN
133 LBL "RDOY"
134 RCL 04
135 4
136 /
137 FRC
138 X=0?
139 SF 07
140 RCL 03
141 .5
142 FS?C 07
143 CHS
144 -
145 RCL 00
146 -
147 CF 29
148 CLA
149 ARCL X
150 "|- DAYS"
151 AVIEW
152 SF 29
153 RTN
154 LBL "DOW"
155 RCL 02
156 5
157 +
158 7
159 /
160 FRC
161 7
162 *
163 RND
164 X=0?
165 "SUN"
166 1
167 X=Y?
168 "MON"
169 CLX
170 2
171 X=Y?
172 "TUE"
173 CLX
174 3
175 X=Y?
176 "WED"
177 CLX
178 4
179 X=Y?
180 "THUR"
181 CLX
182 5
183 X=Y?
184 "FRI"
185 CLX
186 6
187 X=Y?
188 "SAT"
189 AVIEW
190 RTN
191 LBL 08
192 FIX 00
193 365.25
194 STO 10
195 .25
196 +
197 STO 03
198 30.6001
199 STO 01
200 122.1
201 STO 05
202 CLX
203 RTN
204 END

Go back to the HP-41 software library
Go back to the general software library
Go back to the main exhibit hall