Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Changes between Version 1 and Version 2 of PythonChallenge0

Show
Ignore:
Author:
jpelcis (IP: 68.112.60.116)
Timestamp:
08/29/06 22:17:59 (8 years ago)
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • PythonChallenge0

    v1 v2  
    99 
    1010void main () { 
    11        Stdout.print(cast(long)pow(2.0L, 38u)); 
     11        Stdout.print(pow(2.0L, 38u)).flush(); 
    1212} 
    1313}}} 
    1717{{{ 
    1818#!d 
    19        Stdout.print(cast(long)pow(2.0L, 38u)); 
     19        Stdout.print(pow(2.0L, 38u)).flush(); 
    2020}}} 
    2121 
    22 tango.math.pow is used to raise an arbitrary floating point number to an arbitrary power.  This example does 2^38^.  The number is then cast to long so that it will be displayed in integer format instead of a floating point.  The result is printed to the screen. 
     22tango.math.pow is used to raise an arbitrary floating point number to an arbitrary power.  This example does 2^38^.  The result is printed to the screen.