Created
August 25, 2015 00:05
-
-
Save JFFail/72fc582b7760ddba25db to your computer and use it in GitHub Desktop.
Reddit Daily Programmer #229
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#https://www.reddit.com/r/dailyprogrammer/comments/3i99w8/20150824_challenge_229_easy_the_dottie_number/ | |
$number = Read-Host "Enter a number" | |
do { | |
$previous = $number | |
$number = [math]::Cos($number) | |
} while($number -ne $previous) | |
Write-Host $number |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment