Help for this page

Select Code to Download


  1. or download this
    sub double_from_hex { unpack 'd', scalar reverse pack 'H*', $_[0] }
    
    ...
    print(POS_INF, "\n");  # 1.#INF
    print(NEG_INF, "\n");  # -1.#INF
    print(qNaN,    "\n");  # 1.#QNAN