Skip to main content
Commonmark migration
Source Link

#Java, 108, durron597

Java, 108, durron597

class o{{ }public static void main(String...r){System.out.printf("%.6f",('a'*'+'/'\t'-'l')/('m'+'\n'-6.));}}

This was my second pi-printing program today. Given the low precision of this one, the second-most famous rational approximation, namely 355/113, was sufficient to produce the correct digits. It seemed like this fraction should be obtainable with some math on character literals. After some trial and error I finally found an expression ('a'*'+'/'\t'-'l')/('m'+'\n'-6.) which used all the characters it needed to. One convenient thing was that I had the choice between printf or format which both behave identically here.

#Java, 108, durron597

class o{{ }public static void main(String...r){System.out.printf("%.6f",('a'*'+'/'\t'-'l')/('m'+'\n'-6.));}}

This was my second pi-printing program today. Given the low precision of this one, the second-most famous rational approximation, namely 355/113, was sufficient to produce the correct digits. It seemed like this fraction should be obtainable with some math on character literals. After some trial and error I finally found an expression ('a'*'+'/'\t'-'l')/('m'+'\n'-6.) which used all the characters it needed to. One convenient thing was that I had the choice between printf or format which both behave identically here.

Java, 108, durron597

class o{{ }public static void main(String...r){System.out.printf("%.6f",('a'*'+'/'\t'-'l')/('m'+'\n'-6.));}}

This was my second pi-printing program today. Given the low precision of this one, the second-most famous rational approximation, namely 355/113, was sufficient to produce the correct digits. It seemed like this fraction should be obtainable with some math on character literals. After some trial and error I finally found an expression ('a'*'+'/'\t'-'l')/('m'+'\n'-6.) which used all the characters it needed to. One convenient thing was that I had the choice between printf or format which both behave identically here.

replaced http://codegolf.stackexchange.com/ with https://codegolf.stackexchange.com/
Source Link

#Java, 108, durron597Java, 108, durron597

class o{{ }public static void main(String...r){System.out.printf("%.6f",('a'*'+'/'\t'-'l')/('m'+'\n'-6.));}}

This was my second pi-printing program today. Given the low precision of this one, the second-most famous rational approximation, namely 355/113, was sufficient to produce the correct digits. It seemed like this fraction should be obtainable with some math on character literals. After some trial and error I finally found an expression ('a'*'+'/'\t'-'l')/('m'+'\n'-6.) which used all the characters it needed to. One convenient thing was that I had the choice between printf or format which both behave identically here.

#Java, 108, durron597

class o{{ }public static void main(String...r){System.out.printf("%.6f",('a'*'+'/'\t'-'l')/('m'+'\n'-6.));}}

This was my second pi-printing program today. Given the low precision of this one, the second-most famous rational approximation, namely 355/113, was sufficient to produce the correct digits. It seemed like this fraction should be obtainable with some math on character literals. After some trial and error I finally found an expression ('a'*'+'/'\t'-'l')/('m'+'\n'-6.) which used all the characters it needed to. One convenient thing was that I had the choice between printf or format which both behave identically here.

#Java, 108, durron597

class o{{ }public static void main(String...r){System.out.printf("%.6f",('a'*'+'/'\t'-'l')/('m'+'\n'-6.));}}

This was my second pi-printing program today. Given the low precision of this one, the second-most famous rational approximation, namely 355/113, was sufficient to produce the correct digits. It seemed like this fraction should be obtainable with some math on character literals. After some trial and error I finally found an expression ('a'*'+'/'\t'-'l')/('m'+'\n'-6.) which used all the characters it needed to. One convenient thing was that I had the choice between printf or format which both behave identically here.

Source Link
feersum
  • 31.5k
  • 9
  • 65
  • 125

#Java, 108, durron597

class o{{ }public static void main(String...r){System.out.printf("%.6f",('a'*'+'/'\t'-'l')/('m'+'\n'-6.));}}

This was my second pi-printing program today. Given the low precision of this one, the second-most famous rational approximation, namely 355/113, was sufficient to produce the correct digits. It seemed like this fraction should be obtainable with some math on character literals. After some trial and error I finally found an expression ('a'*'+'/'\t'-'l')/('m'+'\n'-6.) which used all the characters it needed to. One convenient thing was that I had the choice between printf or format which both behave identically here.