diff options
author | priyanka | 2015-06-24 15:03:17 +0530 |
---|---|---|
committer | priyanka | 2015-06-24 15:03:17 +0530 |
commit | b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch) | |
tree | ab291cffc65280e58ac82470ba63fbcca7805165 /1332/CH1/EX1.8 | |
download | Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2 Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip |
initial commit / add all books
Diffstat (limited to '1332/CH1/EX1.8')
-rwxr-xr-x | 1332/CH1/EX1.8/1_8.pdf | bin | 0 -> 6151 bytes | |||
-rwxr-xr-x | 1332/CH1/EX1.8/1_8.sce | 19 |
2 files changed, 19 insertions, 0 deletions
diff --git a/1332/CH1/EX1.8/1_8.pdf b/1332/CH1/EX1.8/1_8.pdf Binary files differnew file mode 100755 index 000000000..cb06ca2a1 --- /dev/null +++ b/1332/CH1/EX1.8/1_8.pdf diff --git a/1332/CH1/EX1.8/1_8.sce b/1332/CH1/EX1.8/1_8.sce new file mode 100755 index 000000000..b9713fc8d --- /dev/null +++ b/1332/CH1/EX1.8/1_8.sce @@ -0,0 +1,19 @@ +//Example 1.8
+//Conversion to Base B from Binary System
+//Page no. 8
+clc;close;clear;
+//conversion from binary to octal
+disp(dec2oct(bin2dec('10101101110')),'Octal form of 10101101110 is ='); //inbuilt function
+
+//conversion from binary to hexadecimal
+disp(dec2hex(bin2dec('10101101110')),'Hexadecimal form of 10101101110 is ='); //inbuilt function
+
+//conversion from binary to octal
+s=dec2oct(bin2dec('1011'));
+s1=dec2oct(bin2dec('110011010100')); //inbuilt function
+printf('\n Octal form of 1011.1100110101 is = \n\n %s.%s',s,s1)
+
+//conversion from binary to hexadecimal
+s=dec2hex(bin2dec('1011'));
+s1=dec2hex(bin2dec('110011010100')); //inbuilt function
+printf('\n\n Hexadecimal form of 1011.1100110101 is = \n\n %s.%s',s,s1)
\ No newline at end of file |