What you found is pseudo code
http://en.wikipedia.org/wiki/Pseudocode
Pseudo - code is an unofficial high-level description of the current principle of a computer program or other algorithm.
The := operator := actually an assignment operator. In python, this is just an = operator.
To translate this pseudo code into Python, you need to know the references to data structures and a little more implementation of the algorithm.
Some notes about psuedocode
:= - assignment operator or = in python
= - equality operator or == in python
Please note that there are certain types of pseudocode and your mileage may vary:
Pascal Style PseudoCode
procedure fizzbuzz For i := 1 to 100 do set print_number to true; If i is divisible by 3 then print "Fizz"; set print_number to false; If i is divisible by 5 then print "Buzz"; set print_number to false; If print_number, print i; print a newline; end
C-style pseudo-code
void function fizzbuzz For (i = 1; i <= 100; i++) { set print_number to true; If i is divisible by 3 print "Fizz"; set print_number to false; If i is divisible by 5 print "Buzz"; set print_number to false; If print_number, print i; print a newline; }
Note the differences in the use of parentheses and the assignment operator.
source share