RosettaCodeData/Task/Create-a-two-dimensional-array-at-runtime/Phixmonti/create-a-two-dimensional-array-at-runtime-2.phixmonti
2023-07-01 13:44:08 -04:00

9 lines
471 B
Text

include ..\Utilitys.pmt
"Enter height: " input tonum nl
"Enter width: " input tonum nl
0 swap repeat swap repeat /# create two dimensional array/list. All zeroes #/
-1 get 99 ( -1 -1 ) mset /# set the last element o last dimension #/
pstack /# show the content of the stack #/
( -1 -1 ) mget "Value of the last element of the last dimension: " print print drop
drop /# remove array/list from the stack #/