Close

Coding

Check out our informative posts on such important part of programming as coding

First repository on GitHub

You will be told by me about the typical model control program — Git. It’s pre-mounted on Macos X, and customers to get going you have to obtain it. You are able to deploy the GUI for Git, but to be able to better know how the machine works I would recommend to try and […]

Read More

Design document for the text game

In the new issue of blog about programming, I present the first version of the design document LAM-40 and add to the game the possibility of losing function game_over(). Last time we added lam-40 the element of chance. Now for every action in the game is calculated, the probability of its execution, which depends on […]

Read More

Variables and functions in Python

The period that was final I informed exactly what a Python that was great. People who understand him, possibly and I agree, but you will find people who train development languages that are additional — don’t understand any vocabulary or. Specifically for them I’ll devote the following several articles parsing frameworks that will assist us […]

Read More

Prototype of a text game Part 2

Next we use a for — in loop, which I have before, if I remember correctly, you didn’t. A for — in loop runs as many iterations as elements in the object is placed after the keyword in. In our case, this is a list of actions. The function enumerate() is used to ensure that […]

Read More

Prototype of a text game Part 1

In the new issue of blog about programming, I’m getting a prototype created in the previous release. Last time we brought a text game lam-40 to the first working prototype, which, however, still far from the final version. At the end of the article, I outlined the main disadvantages of this prototype, and today we […]

Read More

Writing a game in Python Part 2

The biggest headache at first — it’s self when you refer to a function or feature class inside of this class, and the comparison operator == instead of = assignment operator beside the conditional operators. Probably about that, and about other you will forget, so watch out for that. By the way, note the key word […]

Read More

Writing a game in Python Part 1

In the new issue of blog about programming, I bring the game LAM-40 (we started writing it in the last issue) to an elementary prototype that already can be tested. Last time we figured out how to prepare your computer to work with python, and now can move on to writing games. In creating any […]

Read More

Loops, conditions and exceptions in Python Part 3

If the condition is false, the interpreter moves to the next unit in line, in our case — the string with the keyword else. This word tells the interpreter that if the condition in if is not executed, you should execute the code inside the else block:. In this block I put the two operations […]

Read More

Loops, conditions and exceptions in Python Part 2

Attention! Only that I brought not very literate code, or rather — not very code. Although the interpreter would accept it, the design that I used, rather typical for other languages, e.g., C (although, in my opinion, still not very elegant). In Python to specify how many times the loop should execute the statements within […]

Read More

Loops, conditions and exceptions in Python Part 1

For a start, something I will explain. The blog is called “I learn to program” and not “I teach program” — in other words, this is not a tutorial on programming. I’m no expert and don’t have the skills of the teacher, but because if you can take it upon themselves to teach someone, it […]

Read More