[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
switch/case
From: |
Helgi Tomasson |
Subject: |
switch/case |
Date: |
Thu, 31 Aug 2000 11:48:31 +0000 |
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;
sincerely yours
Helgi Tomasson
--
Helgi Tomasson FAX: 354-552-6806
University of Iceland PHONE:354-525-4571
Faculty of Economics and Business Administration email:address@hidden
Oddi v/ Sturlugotu
IS-101 Reykjavik
ICELAND
-----------------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.che.wisc.edu/octave/octave.html
How to fund new projects: http://www.che.wisc.edu/octave/funding.html
Subscription information: http://www.che.wisc.edu/octave/archive.html
-----------------------------------------------------------------------
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- switch/case,
Helgi Tomasson <=