I have been looking at Oz as an alternative to Prolog for an Expert System I am building.
 
Just trying to follow the tutorial, however, is causing me difficulty, so I would appreciate any pointers.
 
12.5 works fine.
 
12.7.1, however, appears to do nothing.
 
declare Append in
proc {Append Xs Ys Zs}
   dis 
      Xs = nil Ys = Zs  
   [] X Xr Zr in 
      Xs = X|Xr Zs = X|Zr then 
      {Append Xr Ys Zr}
   end 
end
 
followed by:
 
local X in 
   {Append [1 2 3] [a b c] X}
   {Browse X}
end
 
Shows nothing in the Browser. However, speculating, I changed it to:
 
local X in 
   thread {Append [1 2 3] [a b c] X} end
   thread {Browse X} end
end
 
and I get the expected [1 2 3 a b c]
 
Now trying:
 
local X Y in 
  {Append X Y [1 2 3 a b c]}
  {Browse X#Y}  
end
 
Nothing happens, and speculating on:
 
local X Y in 
  thread {Append X Y [1 2 3 a b c]} end
  thread {Browse X#Y} end
end
 
I get _#_
 
For a novice, it sure would help if the examples actually worked, and some explanation was given.
 
Finally, trying 12.7.4, and speculatively adding thread...end here and there, my computer runs out of memory.
 
Any help on this?
 
Thanks
 
Alex
 
 
_________________________________________________________________________________
mozart-users mailing list                               
[email protected]
http://www.mozart-oz.org/mailman/listinfo/mozart-users

Reply via email to