From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 1733/CH9/EX9.11/9_11.sce | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 1733/CH9/EX9.11/9_11.sce (limited to '1733/CH9/EX9.11/9_11.sce') diff --git a/1733/CH9/EX9.11/9_11.sce b/1733/CH9/EX9.11/9_11.sce new file mode 100755 index 000000000..57ee2fad2 --- /dev/null +++ b/1733/CH9/EX9.11/9_11.sce @@ -0,0 +1,16 @@ +//9.11 +clc; +c=60; +xc= bitcmp (c ,8); +A=xc+1; +d=28; +xd= bitcmp (d ,8); +B=xd+1; +Ans=B+A; +a=dec2bin(Ans) +disp(a) +disp('Since the MSB is 1 so the number is negative and equal to -88') +Ans=B-A; +a=dec2bin(Ans,8) +disp(a) +disp('Since the MSB is 0 so the number is positive and equal to +32') \ No newline at end of file -- cgit