blob: c86b4a42f1c77a9dd058a889086829035799a103 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
// example 1.5/ /
// decimal to hexadecimal conversion//
clc
// clears the screen //
clear
//clears already existing variables //
q =0;
b =0;
a= 82.25
// Enter the decimal number//
format ( 'v' ,18)
//increasing the precision to 18
a= floor (a);
h= dec2hex (a);
// decimal to hexadecimal conversion //
disp ('conversion of decimal given no to its hexadecimal form is :' )
disp (h)
|