Skip to content

Instantly share code, notes, and snippets.

View kylieCat's full-sized avatar
🏳️‍🌈
Codin them thangs

Kylie Rogers kylieCat

🏳️‍🌈
Codin them thangs
View GitHub Profile
@kylieCat
kylieCat / fermat.py
Last active September 12, 2015 23:12 — forked from bnlucas/fermat.py
Fermat primality testing with Python.
def fermat(n):
if n == 2:
return True
if not n & 1:
return False
return pow(2, n-1, n) == 1
# benchmark of 10000 iterations of fermat(100**10-1); Which is not prime.
# 10000 calls, 21141 per second.

To Make Cheese Sauce

I usually make 2 lbs of medium - large shells.

For every lb. of pasta:

  • 1 1/2 cups milk
  • 1 1/2 tbsp. flour
  • 1 1/2 Tbsp. unsalted butter - very important you use unsalted butter throughout
  • 1 1/2 cups shredded cheese
@kylieCat
kylieCat / gist:e33b4ee483b222db0dd5
Last active November 28, 2015 19:59
SO Comments
## Welcome
Welcome to Stackoverlfow! You will greatly increase your chances of getting an answer for your question if you include your input, what you have tried, your expected output vs. your actual output and the full stack trace of any errors you receive. You can also read [this guide](http://stackoverflow.com/help/mcve)