1sem, 7 work in octave

This commit is contained in:
Andrew 2020-01-11 13:11:02 +07:00
parent 3038462693
commit b68323cca1
5 changed files with 127 additions and 0 deletions

View file

@ -0,0 +1,6 @@
function [n] = read_num_code(s)
n = bin2dec(s);
if s(1) == '1'
n -= 2^length(s);
end
end