Wrapped In Python – Edition 6 – Fibonacci Sequence

I have been insanely busy over the past month so I haven’t been spending as much time practicing python as I would have liked.  About a month ago, in my continued obsession with the beauty of mathematics, I gave myself the task of figuring out how to generate the Fibonacci Sequence using python.  I knew,…

Wrapped In Python – Edition 5 – 3rd Grade Math Tutor

I have a daughter in 3rd grade who started the year off with reviews of the addition and subtraction she learned last year.  Fortunately, her school is private and doesn’t do any of the dumb Common Core math that I have seen other parents complaining about.  My daughter understands the concepts of addition and subtraction…

Wrapped In Python – Edition 4 – Primitive Root Finder

Mostly because of their importance in some types of  asymmetric cryptography (Diffie-Hellman, RSA) I have a fascination with prime numbers.  I enjoy occasionally checking on the latest discovery of ever larger prime numbers.  As I write the largest known prime has more than 17, 425, 170 digits in it.  That’s a big-ass number!   Many…

Wrapped In Python – Edition 3 – Prime Number Verifier

In my last post I offered two different examples for generating prime numbers using python.  The first script in that post generated every prime (except 2) from 1 to 9,999,999 and the second script generated every prime in a user-supplied range. It’s neat to be able to generate a bunch of prime numbers but what…

Wrapped In Python – Edition 2 – Prime Number Generator

Perhaps just a step up from writing your first “Hello World” script.  I wrote [yet another] prime number generator.  I’m sure this can be done in a variety of ways but I used what I currently know to figure out how to determine if a number is prime. Here’s the code: #!/usr/bin/env python print “2…

Wrapped In Python – Edition 1 – The Beginning …Again

I have been teaching myself Python for more than a few years. To be clear, that means that I think about python for about a week, do a lot of reading, stay up late trying some real basic code, get distracted by other shiny things, allow weeks or months to go by, and forget almost…