Transportation problem: Difference between revisions

Content added Content deleted
(→‎{{header|REXX}}: flagged as needing improvement, REXX program gets a syntax error.)
m (→‎{{header|REXX}}: another fix - good to have testers out there :-()
Line 3,910: Line 3,910:


=={{header|REXX}}==
=={{header|REXX}}==

{{improve|REXX|REXX program gets a syntax error.}}

Invalid operator character sequence
Error detected at line 117
Source line:
source.r-=sh
^


<lang rexx>/* REXX ***************************************************************
<lang rexx>/* REXX ***************************************************************
* Solve the Transportation Problem using Vogel's Approximation
* Solve the Transportation Problem using Vogel's Approximation
Line 4,027: Line 4,017:
Parse Arg r c
Parse Arg r c
sh=min(source.r,demand.c)
sh=min(source.r,demand.c)
source.r-=sh
source.r=source.r-sh
demand.c-=sh
demand.c=demand.c-sh
m.r.c=sh
m.r.c=sh
If source.r=0 Then Do
If source.r=0 Then Do