summaryrefslogtreecommitdiff
path: root/273/CH25/EX25.10/ex25_10.sce
diff options
context:
space:
mode:
Diffstat (limited to '273/CH25/EX25.10/ex25_10.sce')
-rwxr-xr-x273/CH25/EX25.10/ex25_10.sce14
1 files changed, 14 insertions, 0 deletions
diff --git a/273/CH25/EX25.10/ex25_10.sce b/273/CH25/EX25.10/ex25_10.sce
new file mode 100755
index 000000000..ccea4348e
--- /dev/null
+++ b/273/CH25/EX25.10/ex25_10.sce
@@ -0,0 +1,14 @@
+clc;
+clear;
+//example 25.10
+//binary division
+
+format('v',8);//changing the default precision to 8
+a=11001;//first number
+b=100;//second number
+A=bin21dec(a);//converting a in to decimal number
+B=bin21dec(b);//converting b in to decimal number
+S=A/B; //multiply the two decimal numbers
+temp=dec21bin(S);//converting the decimal product back to binary
+
+disp(temp,'quotient is');//displaying the final output \ No newline at end of file