Skip to main content
added 1154 characters in body
Source Link
recursive
  • 10.4k
  • 20
  • 36

Stax, 19 14 bytes

üâïc-Hò~÷]ó┬ó♪

Run and debug it

Unpacked, ungolfed, and commented, the code looks like this.

|a      absolute value
{HcDw   double until there's no fractional part
@       convert to integer type
:B      convert to binary digits
D52(    drop the first digit, then pad to 52
:b      convert back number

Run this one

Stax, 19 14 bytes

üâïc-Hò~÷]ó┬ó♪

Run and debug it

Stax, 19 14 bytes

üâïc-Hò~÷]ó┬ó♪

Run and debug it

Unpacked, ungolfed, and commented, the code looks like this.

|a      absolute value
{HcDw   double until there's no fractional part
@       convert to integer type
:B      convert to binary digits
D52(    drop the first digit, then pad to 52
:b      convert back number

Run this one

deleted 1063 characters in body
Source Link
recursive
  • 10.4k
  • 20
  • 36

Stax, 19 19 14 bytes

«ö₧σ☼ZÜ▲.├£HD╝♥♀!T·

Run and debug it

Unpacked, ungolfed, and commented, the program looks like this.

|a          absolute value
{hc1>w      halve until <1
{Hc1<n*w    double until >1 OR =0
D52|2*      multiply fractional part by 2**52
@           output as integerüâïc-Hò~÷]ó┬ó♪

Run this oneRun and debug it

Stax, 19 bytes

«ö₧σ☼ZÜ▲.├£HD╝♥♀!T·

Run and debug it

Unpacked, ungolfed, and commented, the program looks like this.

|a          absolute value
{hc1>w      halve until <1
{Hc1<n*w    double until >1 OR =0
D52|2*      multiply fractional part by 2**52
@           output as integer

Run this one

Stax, 19 14 bytes

üâïc-Hò~÷]ó┬ó♪

Run and debug it

Source Link
recursive
  • 10.4k
  • 20
  • 36

Stax, 19 bytes

«ö₧σ☼ZÜ▲.├£HD╝♥♀!T·

Run and debug it

Unpacked, ungolfed, and commented, the program looks like this.

|a          absolute value
{hc1>w      halve until <1
{Hc1<n*w    double until >1 OR =0
D52|2*      multiply fractional part by 2**52
@           output as integer

Run this one