Skip to content

Instantly share code, notes, and snippets.

@abdollar
Created December 8, 2011 23:51
Show Gist options
  • Save abdollar/1449318 to your computer and use it in GitHub Desktop.
Save abdollar/1449318 to your computer and use it in GitHub Desktop.
What is the largest prime factor of the number 600851475143 ?
octave:2> max(factor(600851475143))
require 'prime'
600851475143.prime_division.flatten.uniq.sort.last
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment