Mercurial > hg > octave-lyh
comparison scripts/strings/bin2dec.m @ 2314:949ab8eba8bc
[project @ 1996-07-12 03:58:02 by jwe]
author | jwe |
---|---|
date | Fri, 12 Jul 1996 03:58:02 +0000 |
parents | 5ca126254d15 |
children | b5568c31ee2c |
comparison
equal
deleted
inserted
replaced
2313:5ca126254d15 | 2314:949ab8eba8bc |
---|---|
20 ## usage: bin2dec (x) | 20 ## usage: bin2dec (x) |
21 ## | 21 ## |
22 ## Returns the decimal number corresponding to the binary number in | 22 ## Returns the decimal number corresponding to the binary number in |
23 ## quotes. For example, bin2dec ("1110") returns 14. | 23 ## quotes. For example, bin2dec ("1110") returns 14. |
24 | 24 |
25 ## Author: jwe | |
26 | |
25 function y = bin2dec (x) | 27 function y = bin2dec (x) |
26 | 28 |
27 ## Original version by Kurt Hornik <Kurt.Hornik@ci.tuwien.ac.at>. | 29 ## Original version by Kurt Hornik <Kurt.Hornik@ci.tuwien.ac.at>. |
28 | 30 |
29 if (nargin != 1) | 31 if (nargin != 1) |