[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


From: John W. Eaton
Subject: switch/case
Date: Fri, 27 Oct 2000 15:15:01 -0500

On 31-Aug-2000, Helgi Tomasson <address@hidden> wrote:

| What is the current status on the switch case .  In the enclosed program
| octave -2.0.16 does not like that method can be either a 6 characer
| thing
| or an 8 character thing.  If I add two blanks, i.e.
| method='linear  '
| and similarly in the case statement thing seem OK.
| function  method(method,...)
| switch method;
| case  'linear';
|      disp ('method is linear');
| case 'bilinear';
|      disp ('method is bilinear');
| endswitch;
| endfunction
| In Matlab I think the following should work
| switch method;
|   case {'linear','quasi-linear'};
|     disp ('method is linear or quasi-linear'};
|   case 'bilinear';
|      disp ('method is bilinear');
|  endswitch;

Thanks to Paul Kienzle  <address@hidden>, the current
CVS sources handle these cases correctly.


Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:
How to fund new projects:
Subscription information:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]