Anyone want to venture a guess at the first prime number above 1,000,000,000,000? I used my program shown in the C++ section to calculate it... you won't win anything if you get it, but I thought it might be fun. Please excuse my enthusiasm about this, but this is the first program I have written mostly on my own, but with some crucial help from people, that did anything even remotely useful and worked!
4 2321 Here is what the python code looks like.
Much more efficient than mine, LOL.... It took me somwhere between 5-10 minutes (i wasn't counting) to calculate that the first prime after 10^15... which is 1,000,000,000,000,037
Much more efficient than mine, LOL.... It took me somwhere between 5-10 minutes (i wasn't counting) to calculate that the first prime after 10^15... which is 1,000,000,000,000,037
So you ran it? I didn't try it. I bet it at a huge chunk of memory at 10^15...
I haven't run the python code, but my C++ did calculate it to that... I've since become slightly obsessed with prime numbers, LOL, joined GIMPS, been reading books on them.
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Dag |
last post by:
Is there a python module that includes functions for working with prime
numbers? I mainly need A function that returns the Nth prime number and
that returns how many prime numbers are less than N,...
|
by: Greg Brunet |
last post by:
In doing some testing of different but simple algorithms for getting a
list of prime numbers, I ended up getting some results that seem a bit
contradictory. Given the following test program...
|
by: Rahul |
last post by:
HI.
Python , with its support of arbit precision integers, can be great
for number theory. So i tried writing a program for testing whether a
number is prime or not. But then found my function...
|
by: don |
last post by:
Ok, this is a homework assignment, but can you help me out anyway...... I
need a routine for figuring out if a number inputted by the user is a prime
number or not...... all I'm asking for is Not...
|
by: Tuvas |
last post by:
I have made and recently posted a libary I made to do Modular
Arithmetic and Prime numbers on my website at
http://www.geocities.com/brp13/Python/index.html . I am currently in a
crypotology...
|
by: wudoug119 |
last post by:
This is my code and it will take any number that I input and say it is a prime number. Please help me...
int Prime(int prime) //declares isPrime as a function using integers
{
...
|
by: newstips6706 |
last post by:
1, 2, 3, 5, 7... PRIME Numbers
________________________________
Definitions
What is a PRIME Number ?
|
by: electric916 |
last post by:
I have a homework assignment i Am totally confused on. I started with a basic code to determine if a number is prime or not, but need guidance from here. I will post assignment details then what I...
|
by: sigkill9 |
last post by:
I'm doing some reading in a python book and am doing one of the chapter exercises but I cant figure out how to get it to work and was hoping some of you python guru's could help out?
Heres...
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
| | |