The following warnings occurred:
Warning [2] Undefined array key 140505 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 140516 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 140536 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $thread - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $fid - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 140516 - Line: 331 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 331 errorHandler->error_callback
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 304 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 140536 - Line: 331 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 331 errorHandler->error_callback
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 304 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $theme - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $theme - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $lang - Line: 5 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 5 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Attempt to read property "messages_in_thread" on null - Line: 5 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.15 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 5 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks





1d Rubik's Cube for HP 35s



#4

I bought myself an HP35s recently and as an excersize I programmed this game for it. Not that it can compete with this game, but still.

The goal is to arrange digits 12345678 in order.
The "move" takes a block of 4 digits located somewhere within the sequence and reverses them.

Start with XEQ X. This will produce some permutation of digits 1..8. Top row shows number 12345 -- these are 5 possible moves. "1" will reverse first 4 digits, 2 will reverse 4 digits starting with the second, and so on.

Type n R/S to perform move number n.
Repeat until digits are in order.

X001 LBL X
X002 ALL
X003 12345678
X004 STO X
X005 9
X006 STO J
X007 RANDOM
X008 5
X009 ×
X010 IP
X011 XEQ X028
X012 DSE J
X013 GTO X007
X014 12345
X015 RCL X
X016 STOP
X017 IP
X018 x<=0?
X019 GTO X014
X020 5
X021 x<>y
X022 x<=y?
X023 XEQ X025
X024 GTO X014
X025 +/-
X026 5
X027 +
X028 10^x
X029 STO K
X030 RCL X
X031 x<>y
X032 INT÷
X033 x<> K
X034 4
X035 STO I
X036 RCL- I
X037 10
X038 ×
X039 RCL K
X040 LASTx
X041 STO÷ K
X042 RMDR
X043 IP
X044 +
X045 DSE I
X046 GTO X037
X047 RCL K
X048 FP
X049 10000
X050 ×
X051 -
X052 ×
X053 STO+ X
X054 RTN

Uses registers X, K, I, J


Edited: 28 Sept 2008, 5:02 p.m. after one or more responses were posted


#5

Nice game.

Now you should substitute the HTML groups with textual forms:

&#8804; with <= (e.g. x<=y?)
&#8596; with <> (e.g. x<>y)

This would improve readability.

-- Antonio

#6

Interesting little puzzle. I seem to remember something similar for the Casio-FX602P -- I don't remember if I wrote it or it came in the program library. The move possibilities were more limited from memory.

The largest number of moves to solve any legal position is 10 (e.g. 24175386). There are also unsolvable numbers.

- Pauli


Possibly Related Threads…
Thread Author Replies Views Last Post
  HP-71B - thanks to Marcus von Cube for MATH ROM article Michael Lopez 2 1,403 03-03-2013, 07:19 AM
Last Post: Paul Berger (Canada)
  Cube root on standard calculator Thomas Klemm 22 6,319 11-09-2012, 06:11 AM
Last Post: Pierre
  Archaeology attack: Rubik's Cube on the 41 Ángel Martin 17 3,567 05-26-2010, 03:03 AM
Last Post: Paul Dale
  Merry X-Mas: ICEBOX.ROM version 1D Geir Isene 1 968 01-10-2009, 04:51 PM
Last Post: Geir Isene
  HP 50G Cube Root of Negative Hal Bitton in Boise 8 1,938 10-16-2008, 06:52 PM
Last Post: V-PN
  Cube root of negative number (HP 50G) macky 3 1,137 09-18-2008, 06:06 AM
Last Post: Walter B
  A practical application for cube root Karl Schneider 22 14,719 01-30-2007, 09:13 PM
Last Post: Ron
  49g+ Cube roots Kellie 15 3,412 02-26-2004, 08:04 PM
Last Post: Kellie

Forum Jump: