Програмуйте із задоволенням! Ця книжка легко та невимушено допоможе вивчити основи однієї з найпопулярніших сучасних мов програмування – Python, що завдяки простому і зрозумілому синтаксису особливо пасує для новачків. Крок за кроком, на простих та дотепних прикладах та з допомогою смішних завдань ви зможете пізнати тонкощі мови Python. Навчитеся використовувати основні елементи цієї мови – списки, функції, модулі, малювати вбудованими інструментами Python та анімувати зображення і навіть зможете написати дві справжні комп’ютерні гри: забавку з м’ячем «Скок!» та бродилку «Містер Руки-палички біжить до виходу».
Jason R Briggs grew up in Hawke's Bay, on the east coast of New Zealand, but for the last 17 years has divided his time between NZ, Thailand and England.
Which is entirely far too much time spent strapped inside a glorified tin can with wings.
He currently lives in England, in a small village just outside of London, where he spends much of his time grumbling about the weather... the people on the Underground... the distinct lack of anything resembling a proper antipodean lager.
The book might be for kids but it is a great place to start if you are wanting to get into programming Python. The chapters are nice and easy to understand and demos are easy to follow. As you get near the end of the book you get to create a few games, the first few are easy to do and work well, also fun to play. The last game though is a complete b****** I've spent ages on it, I have got the background for the game, I have some platforms and the exit, my little stickman is there but the little git will not move. The book supplies the full code at the end, I've compared and see no difference. Time to give up with python and stick to drinking tea methinks.
As I have been working with my daughter to learn programming, we have been focusing on learning Python. We chose Python primarily because it was something I felt we could both come at from a similar frame of reference. I had worked with Python but in limited capacity, and she had not really worked with any programming languages. By working on Python, we could be somewhat closely matched with what we were learning.
NoStarch Press has a number of books that are ideally suited for younger programmers, and to that end we both decided to look at the books together. We will be doing three “for Kids" books reviews during February, provided we can get through all of them. All journeys have to start somewhere though, and this journey will start with Python for Kids.
Python for Kids is written in a way that lets the user, whether they are kids or adults, readily get into the material and see how the examples work and try them out for themselves.
Chapter 1 starts out with installing and using Python 3. Be aware that there are some subtle differences with Python 3, one of the main ones being the parentheses required when using the print(“text goes here”) function (yeah, like that ;) ).
Chapter 2 introduces the user to calculate values using simple equations via operators, using parentheses to ensure the desired order of operations, and creating and using variables to store values for use in those calculations.
Chapter 3 introduces strings, lists, tuples, and maps, each of which allows the user to manipulate text in a variety of ways. Each of the approaches has rules as to how to move items and how they are represented, ranging from simple strings with are just quoted sentences, up to maps which have keys and values that can be called as needed.
Chapter 4 introduces the user to drawing methods, and in this case, that involves using a module called turtle (which in turn uses a tool called tinter). Using this tool, we can actually draw the turtles movements with lines moving left and right, moving forward and backward, as well as starting and stopping with up and down commands.
Chapter 5 focuses on asking questions and responding based on the response the system gets. For experienced programs, this i about if statements and their related commands (elif, else) and how commands allow for combining conditions (using and/or) and converting values (using int, str, float and none).
Chapter 6 talks about “Going Loopy” which, as you might guess, deals with handling loop conditions and repetitive tasks. for and while loops are covered, and break conditions are shown to, well, break out of loops.
Chapter 7 talks about ways to recycle code and reuse it defining and using Functions and importing Modules. Variable scope is also covered so as to see where values are assigned, used and passed back and forth.
Chapter 8 focuses on the things in python, otherwise known as classes and objects. This chapter covered the details of classes and how they an be used to create instances, and how objects can be created, call functions to work with objects, and assigning object variables to save values in those objects.
Chapter 9 covers the various built-in functions available in Python, those that we can import into Python programs and use directly (functions like abs, bool, print, float, int, len, etc) as well as howe to open and manipulate files.
Chapter 10 covers a variety of helpful modules, such as copy, keyword, random, shuffle, and the sys module that allows the user to control the Python shell itself, reading input with stdin, writing output with stdout, telling time with the time module, and using pickle to save user information in files (yes, there’s a module called pickle ;) ).
Chapter 11 revisits turtle, and how we can use it to draw a variety of items. including basic geometric shapes, changing the pen color, filling shapes and reusing steps in functions to combine drawing shapes and using multiple colors in one function call.
Chapter 12 covered using tkinter to make “better graphics” and my oh my does this take me back. I used Tcl/Tk back in the 90s for a number of things, and the syntax to use tkinter is very familiar. Simple shapes, event bindings so objects can move when keys are pressed, using identifying numbers to move shapes and change colors are all covered here.
Part II gives the user a chance top practice the programming chops they have developed in the first Part by making a ball bouncing game called, appropriately enough, Bounce!
Chapter 13 starts out using the tinter module, in which we can create a class for a ball and move it around the screen. Coordinates can be set so that it will bounce off of the top and corners of the screen, and a randomized option so the ball has a dynamic movement.
Chapter 14 continues with creating classes for the paddle, and using coordinates to see if the ball hit the paddle. Event bindings tie the left and right arrow keys to control the paddle, and make it so, if the player misses the ball, the game ends when the ball hits the bottom.
Part III continues the ideas so far shown with “Mr. Stick Man Races for the Exit”.
Chapter 15 shows how to make graphical images of, you guessed it, a stick man (using GIMP to make the actual images) and making the backgrounds of the images transparent so they won’t cover up other things.
Chapter 16 covers creating a Game class making a background image. By using functions called within_x and within_y, we can determine if items have collided with other items. We also discover Sprites and a sub-class, PlatformSprite, to draw the platforms on the screen.
Chapter 17 walks through the details for taking the pictures we created for Mr. Stick Man back in Chapter 15 and setting up options for the figure to move, turn and jump.
Chapter 18 finishes off the Stick Man game, and shows that putting together a working game is not trivial, but it’s also not a huge endeavor either. We focus on using the images we made for Mr. Stick Man so he appears to be running, use collision detection to tell if he hits the sides of the canvas or another object, and have Mr. Stick man drop if he runs off the edge of a platform. We also make a door that Mr. stick man can go through, ending the game.
The book also provides an Afterward that discusses some additional options for doing basic game development Alice, Scratch and Unity3D, PyGame, which is a dedicated library for making games, band a discussion of other programming languages and a super quick look at what they do , where to get them, and what it takes to make a “Hello, World!” program. The Appendix highlights keywords in Python, and the glossary defines a number of words kids might not hear in their everyday interactions.
Bottom Line:
Python for Kids clocks in at a little over 300 pages, but you won’t feel like it as you work through it. There are numerous small projects and samples to examine, and all of the solutions to the puzzles and challenges are available at http://python-for-kids.com/. While this book is geared towards kids, there’s plenty in here to keep adults engaged and focused. Often, programming books are plagued with the “implied knowledge” trap that happens so often, where small projects give way to bigger ones, without a clear understanding of how the jump was made. Python for Kids does a very good job of avoiding that problem. Having kids as the primary audience, they take their time explaining key areas, and yes, for programmers with a little work under their belts, this is going to probably seem remedial, but as an introduction to Python, I think it’s first rate.
If you are looking to give your kids a kick start in learning how to program, if Python seems like an interesting language to start with, and if you’d like to have a couple of tangible projects to play with and augment as you see fit, then Python for Kids should be on your short list of programming books… provided having fun while learning is a priority.
Можливо книга і розрахована на дітей, проте я не втрималась і тепер у мене на поличці є це чудове видання.
Всі 5 зірок, як автору, так і видавництву, перекладачу та ілюстратору.
Перше що подобається, так те що книга практична, зацікавлює і мотивує з перших сторінок. Особливо класно пояснюється теоретична частина, просто, з гумором, без навантаження. Сподобалось, що розв'язки до завдань з програмування, описані на сайті видавництва.
І останнє, дуже приємно, що книжка українською мовою! Круто, що є можливість вивчати новий матеріал рідною мовою.
some notes: - The book is very easy and greatly organized so that you can get things done without being distracted with a missing point or something like that you might find in other books.
- A good way in explaining the code, it shows you what's before it, what precautions you should take. Mostly reminds you with the common mistakes you might make while writing some piece of code.
- One thing that might kill you! At the last of the explanation when the writer put all the code of the example together, the code isn't commented and also not numbered! you will be confused, especially when you get to the last game, the writer put the code altogether at the end, and you will try to get work until you get crazy! and as you know python interpreter needs clear indentation to start interpreting your code, the thing here is you mostly can't copy and paste the code :3 because you'll get wrong indentation in your text editor :v
This booked helped. Can’t say it wasn’t hard, but it gave me the basics. Of course a lot of free courses might be more effective and give you a good use, but I have some nostalgia for this book. А взагалі то це не погана книжка. Іноді доводилося заглядати в інтернет, щоб зрозуміти деякі речі краще, але це нормально)
В какой-то момент я решила забить и не писать все коды, а просто читать и впитывать информацию; наверно, в данном контексте это лучшее решение. Если вы хотите заинтересовать ребенка программированием, это крутая книга. Огромное количество веселых задачек, прикольных картинок, которые показывают, как действует код, в конце даже построчник двух элементарныых, но все же игр. Но если вы, как я, взяли эту книгу для того, чтобы разобраться, то, боюсь, одного этого текста станет недостаточно. Частые перепрыгивания с темы на тему, тут мы вам не объясним, просто показываем на пальцах, вы уж нам поверьте, а эта тема слишком сложна, поэтому мы вам про нее не рассказываем, просто знайте, что вы еще до нее не доросли. И вроде хорошо, что все эти моменты, по крайней мере, указывают, и их можно нагуглить при желании, но. Но но но. Системное обучение? Нет, не слышали.
This is a good enough book to refresh or learn Python programming for the first time, be it for kids aged 12-14 or adults. I wish I had seen this one earlier. It's simpler than No Starch Press books to read. I used this book as a reference for online teaching my YouTube course for kids. Worth it.
Similar to “ JavaScript for kids” , in the first half of the book the explanation is great for beginner , but then it suddenly accelerates in difficulties and when we get to the 2nd games examples the author had skipped so many steps and concepts it’s really not easy to follow. The 2 games especially the last one is where I spent most of my time on in this book. I am still not confident I fully understand the design but I am able to extract some smart coding ideas and concepts onto my note. So I get a lot out of it. But I am very disappointed that a lot of basic concepts on data structures are not explained before the game examples ( can object be set as parameters, can variable in for loop can be set as variable for other objects ,can object in list be used in object variable in other class etc. ), you will need to figure all these out first before you are able to understand the code. It can be easier.
Great explanation in the beginning but the games in the end are a just too tough for beginners ,it gives people false sense of hope they would really do that after reading the first half of the book. It is bittersweet though when you finally understand the design, but I don’t think it is the best guide, certainly not for (average) kids.
The book is nothing less but a joy to read for grown ups and a must read for kids. It touches upon programming in such a light, colorful and enjoyable way that it makes you wish this book was around when you were a kid.
It was an absolute joy to complete this book with my 7th grade son. I had first started in 6th grade with a book that controlled Minecraft using Python. While this started off pretty good, I found myself losing his attention quickly as he just wanted to play the game. He learned basic concepts such as integers vs floats, strings, the benefits of loops when building structures, the benefits of script files, and understanding the game space in x-y-z coordinates. Unfortunately, we never finished the book due to this attention issue and teaching came to a halt.
My next attempt was with Microsoft Unity Game Development Software which used scripts written in C#. I purchased him a gaming computer under the premise that he'd actively learn to code (I was desperate ok). My rationale was that if I could get him to finish that first game "from scratch", he'd be locked in like I was when I made my first "Tank-V-UFO Game" with the Commodore VIC20. We completed the Spaces Shooter Tutorial which created an "Asteroids" type of game and published it online so his friends could play. I thought it was amazing but he didn't. I could not believe it. He acted like this was not a big deal and he didn't even want to share the link with his buddies. He later told me that he felt like he didn't actually do anything. I suspect this is because he didn't really grasp 'coding' from the tutorial. While we used "objects" and assigned/used properties, and created custom methods using c#, much of the code was pre-written, and when classes were used, I didn't re-explain them "as if I was speaking to a 7th grader".
With my tail tucked, I picked up this book and it was perfect! It had a good flow of concepts, the examples were relevant, they built on top a previous lesson, and the author used kid humor that my son appreciated. I knew the concepts were getting through because he would rarely type the examples verbatim. He'd change variable names and values to his liking and on some occasions, he'd merge examples.
The book ended with the creation of a 2D game in which a stick man walks and jumps onto platforms trying to get to the top. I'm not too proud to say that I learned a great deal with this example as well. He created sprites using Photoshop (the book used GIMP), animated them by cycling through a list, and developed decision logic based on relative positioning of the stick figure, platform, and window limits. I was particularly impressed in the way the author explained his concepts "as if he was speaking to a 5th grader". I rarely felt the pressure to re-explain concept using simpler terms. What I liked most about this example was that it was truly "from scratch".
He has since went beyond that last example using a different set of sprites. For example, instead of the stick figure he drew, he found sprite sheets of Naruto and Batman and used them instead. He also changed the platform design and background design. Now he says he has different 'skins'..... Ok
I cannot say that this book would have worked so well had we started with it. There were many time I referred to a similar concept in Microsoft Unity or in Minecraft. There is also the fact that he was a year older so that could have played a role.
Lastly, about a week after we finished the book, I picked up one of my JAVA books and turned to a page randomly and asked him to tell me what the code was doing. He understood the gist and his smile of accomplishment afterward was priceless.
I could not be happier. I think he crossed the threshold.
Кульмінацією книжки стає написання відеогри. Яка хоч і не шедевр, але гарний початок.
Нажаль для того щоб до неї добратись доведеться освоїти кожну дрібницю. Котрі ніби ніяк не пов'язані. Й лише в кінці все збирається воєдино. Все це збільшує ризик того, що читач так і не добереться до фінального проекту. Під кінець забагато коду між запусками. Великий ризик припуститись помилки і потім довго намагатись зрозуміти в чому ж помилка.
Мені більше подобається миттєво бачити результат роботи. Для чого потрібно написати трошки коду, запустити програму, подивитись, що вона робить. Після дописати ще трошки коду і повторити. Може це стара школа? Дуже довго думати, написати багато коду і надіятись, що він з першої спроби спрацює. Після чого, або святкувати, або довго розбиратись чому не спрацювало.
Можливо все це і робить книжку хорошою? Якщо людина не вмотивована прочитати книжку то чи буде вона вмотивована програмувати?
A good book for beginners to programming. It's is a simple book and easy to understand. The book is targeted for younger audiences so there is a lot of the stuff is on the easier and less complicated side. Although it is a simple book, I recommend some other books to learn Python or just use the manual included with the software to learn the program. The book is set up into 3 parts; 1 part telling you what the basic functions are, like variables and loops, and another 2 parts on projects for practice. A fun thing about the book is that it has these little illustrations sometimes and it makes the book much better. I feel like the book targets a younger audience while the stuff in the book is for an older audience. That is why I gave this book a 3/5.
Такой милый учебник! :) Заметно, что написано для детей, весело, легко, доброжелательно, ну и примеры навроде: if age >= 23: print 'you are too old' :) ничего нового и сложного не встретила, но весело провела время, освежила давно позабытое, и получила удовольствие от написания игры и поиска своих косяков в процессе :) опечатки, табы - все мое, родное) Для серьезного изучения питона, конечно, этот учебник не подойдет, но для первого веселого знакомства - вполне :)
I found this to be an excellent introductory book for python. It clearly introduces the terms, gives nice summaries at the end of each chapter, explains in a verbose way the intricacies of error messages, while it does not shy away from introducing actual terminology. If I would want to learn Python, I would not be afraid to start out with this book. The "for kids" does not diminish the contents informative value, you just encounter some silly pictures and fun examples.
I may be slightly biased as the author is my dad, but as a child I loved working through this book. Though at times not quite engaging, my 9 year old mind fully enjoyed every single one of the sections, especially making my own stick-man game. Throughout my schooling career I have returned to the book in order to reference or re-read certain sections.
All in all this book will have a permanent place on my shelf for the rest of my life.
Геть непогана книжка, як для вступу в програмування. Не найкраща, але гарно проілюстрована, тому тримати її в руках справжнє задоволення.
З мінусів: треба читати купу додаткових ресурсів та книг, щоб по-справжньому в'їхати в тему. Це не стільки недолік книги, скільки — так влаштований наш мозок.
This is a great book for people looking to learn Python. It’s well written and easy to follow with lots of code examples. It’s a great primer and I recommend it to anyone especially those who want to teach Python to younger students.
This entire review has been hidden because of spoilers.
Excellent book. Need to get a personal copy to use in my 8th grade classroom teaching Python. Each time I signed it out of the library, it was put on 'hold' and I had to return it before I wanted to.
Best intro to Python programming book out there. Jason R Briggs covers basic computer science concepts such as classes and then utilizes them later on in a more complicated setting while building a few fun games.
Un excelente libro para iniciar en el mundo de la programación a pequeños.
Este libro es parte de mi bibliografía básica explicar conceptos básicos de programación. Viene mucho manejo de librerías y como redactar los algoritmos de los ejemplos que vienen en el mismo libro
This was a great book for teaching Python For Kids (PFK). PFK is actually the French Canadian version of KFC, but unlike that, this version of PFK is good for kids!!
I learned a lot, and it was very valuable information for learning to teach coding to kids.
While I enjoyed reading as an adult, this book is actually aimed for kids who are into programming (as the title hints). It's more into practical side of programming, hence kids would keep their attention.
Хороша книга для початківців. В цілому вона дає хороший початок для програмування (і не тільки для Python: в багатьох мовах програмування є багато схожих речей). В книжці вивчаються основи Python і також розглядаються деякі найбільше використовувані вбудовані функції і модулі.
I loved this book because it shows you how to understand the code that you were writing reading this book. This was my first approach to the Python world and I enjoyed so much.
Text is broken up with illustrations and presented well Still a challenging concept for me to grasp- but this edition is better than others on the market currently.