diff options
Diffstat (limited to '911/CH1/EX1.4/ex_1_4.sce')
-rw-r--r-- | 911/CH1/EX1.4/ex_1_4.sce | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/911/CH1/EX1.4/ex_1_4.sce b/911/CH1/EX1.4/ex_1_4.sce new file mode 100644 index 000000000..8bcec0e92 --- /dev/null +++ b/911/CH1/EX1.4/ex_1_4.sce @@ -0,0 +1,15 @@ +//Example 1.4//
+//decimal to octal//
+clc
+//clears the command window//
+clear
+// clears the variables//
+q =0;
+b =0;
+a= 73.75
+// Enter the decimal number//
+format ( 'v' ,18)
+//increasing the precision to 18
+a= floor (a);
+h= dec2oct (a);
+printf ("The hexadecimal equivalent is = %s" ,h)
\ No newline at end of file |