"Programming for beginners" + probability theory

    Interesting thing: any video programming course, from PHP to Java, includes a chapter for beginners - most often it talks about the basics of structural programming: variables, branches, and loops.

    Therefore, we decided to solve this problem once and for all - and took off the course " Programming for beginners " , which will help the very beginners understand and understand these basic concepts, as well as try them out. The course is built as a series of video lessons using the example of probability theory (to make it more interesting).

    Video announcement of the course:

    One of the first videos explains why learning to program at all: there is so much around everything only thanks to mass production, assembly line and automation. Therefore, if we are not slaves in order to repeat stupid and tedious work, then we need to learn to program - Leibniz said about this in the XVII century, only in other words.

    The course is made for the JavaScript language (as an equal member of the C-family languages), and students get the basics of working with it directly in the browser console - conveniently, because you do not need to install anything.

    Of course, the students of this course will not only comprehend the theory of structural programming - they need to give an example of some simple project to consolidate the knowledge gained.

    If you think that this is easy - take and come up with an example of a project when you only have variables, conditions and cycles from the toolkit, then this is not entirely true. What would you suggest? Keep in mind that almost any application involves entering data in one form or another - and we decided not to touch on this in the course. So neither you need input forms, nor reading from a file, nor database queries.

    Therefore, they came up with the following task: to generate a win-win strategy for playing Rock-Paper-Scissors, then you can take a random number generator as a data source. If you believe Wikipedia and the university course on probability theory, then if you play random “scissors-paper” games and play a lot of times, the result will be close to a draw (you can check on this robot ).

    A few screenshots from the course

    We decided to explain the variables on apples. “ You have 2 apples. Someone took one apple from you ... ”, says a girl with blue hair. We took this simple task in order to illustrate the fact that a variable has a constant name and a mutable value. Variables from everyday life: the dollar exchange rate, the price of a barrel of oil, my salary, today's number, etc.

    The conditions are also intuitive. “Red - stand, green - go” is a traffic light as an example of branching logic.

    Figure 1 - Condition

    Here the cycles may not be clear to everyone. Although this is an operation requiring the repetition of the same actions, students have no experience in programming cycles. Therefore, the ideas of counting iterations and what will happen if the cycle is driven endlessly are considered in detail.

    Figure 2 - cycle

    The result of the program visually looks like this (at the same time, we figured out what Unicode characters are and used them in practice):

    Figure 3 - program for generating a strategy in “Stone-paper-scissors”

    I hope we tried for good reason, and you will like the course! Emm, has he already said that it is free? ..

    PS Subscribe to our updates - soon there will be an announcement of a few more interesting things, more serious.

    Also popular now: