Qual Seu Fator de Safadeza?

Posted on Tue 08 December 2015 in python • Tagged with python, notserious

Note: This post is in portuguese because it deals with a brazilian meme that wouldn't make much sense in english.

Recentemente me mandaram a imagem abaixo, que supostamente é uma questão passada em um curso de programação.

Cellular Automata in Python Part 2: Harder, Better, Faster, Stronger (but Mostly Faster)

Posted on Tue 15 September 2015 in python • Tagged with python, cellular-automata, pypy, numpy

Last time we ended up with a nice little class that implemented our one dimensional cellular automaton. That code works perfectly fine if all you want is to play around with it and make nice figures, but we have bigger plans here. Before further exploring this subject, we might wanna test our code for performance, as some speed is gonna make our work easier in latter posts.

Continue reading

Cellular Automata in Python Part 1: Do You Think This Is a Game of Life?

Posted on Fri 04 September 2015 in python • Tagged with python, cellular-automata

A common exercise in programming is making an instance of Conway's game of life. It's a great example of a simple set of rules that generate incredibly complex behavior. And if you're like me, you're sick of it. I mean, it's such an overused example and it got really old by now, which is a shame because the subject of cellular automata (of which the game of life is but a single example) is very fascinating. This inspired me to make a series of posts exploring the subject and it's applications. And I decided to do it in python, because python is so hot right now, you guys.

Continue reading