ieee754 by yt

with text_io;use text_io;procedure q is\x0d
r:long_long_float;d:long_float;s:float;type u is mod 16;t,h:string:="0123456789abcdef";type\x0d
a is array(0..19)of u;pragma pack(a);z:a;for\x0d
z'address use r'address;for d'address use r'address;for s'address use r'address;l:natural:=19;begin\x0d
get(t(1));while' '/=t(2)loop get(t(2));end\x0d
loop;r:=long_long_float'value(get_line);z(0):=z(0)+(-z(1))/15-(2-z(0))/12-(5-z(0))/15;if's'=t(1)then\x0d
s:=float(r);l:=7;elsif'd'=t(1)then d:=long_float(r);l:=15;end\x0d
if;for i in 0..l loop put(h(natural(z(l-i))+1));end loop;new_line;q;end;

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page