Ruby For Kids For Dummies ( For Kids For Dummies )

Description

The fun way to introduce coding with Ruby to kids

If you don't have the chance to take coding classes at school or in camp—or if you just want to learn on your own—Ruby For Kids gears you up to expand your technology skills and learn this popular programming language. Written in a way that's easy to follow—and keeping the super tech-heavy stuff to a minimum—it quickly and easily shows you how to use Ruby to create web and mobile applications with no experience required.

Ruby is considered one of the best and simplest languages to start with when you're learning coding. This fun and friendly guide makes it even easier. Broken down into simple projects designed to appeal to younger programmers, Ruby For Kids gets you up and running with core coding concepts in no time. Before you know it, you'll be tackling hands-on projects, enjoying the support of a vibrant community, and feeling a sense of accomplishment as you complete projects.

  • Navigate the basics of coding with the Ruby language
  • Use Ruby to create your own applications and games
  • Find help from other Ruby users
  • Offers tips for parents and teachers helping kids learn Ruby

So what are you waiting for? Ruby For Kids has everything you need to get in on one of the most popular topics around!

Chapter

If you’re on Mac OS X

Project 2 Big Numbers

Starting Interactive Ruby

Entering Numbers

Doing Some Basic Math

Supersizing the Math with Huge Numbers

Adding Memory by Storing Results in Variables

Using Variables to Repeat a Calculation

Fixing Things When Something Goes Wrong

Trying Some Experiments

Project 3 Bigger Hello World

Starting Interactive Ruby

Knowing How Letters and Words Differ from Numbers

Doing Math with Words

Doing Other Things with Strings

Storing Strings in Variables

Making Some Big Letters

An easy way to combine words

An advanced way to combine strings together

Creating the letter H

Creating the letter E

Creating the letter L

Creating the letter O

Combining the letters into a word

Trying Some Experiments

Part II Programmers Are Lazy! Stop Typing So Much!

Project 4 Shapes

Organizing a New Project

Printing versus Using puts

Getting Input with gets

Running the Program on the Command Line

Creating Code to Draw a Rectangle

A first version of the rectangle

A reusable rectangle

Creating Code to Draw a Triangle

Drawing a House Using Your Two Shapes

Testing Your Program

Trying Some Experiments

Project 5 Simple Adventure

Organizing a New Project

Planning the Project

Looking at the Program Skeleton

Creating the Main Game Loop

Creating the room description and actions

Responding to player actions

Creating Game Rules Methods

Adding methods needed for the move command

Adding methods for handling the fighting monster

Adding methods for treasure searches

Creating Game Helper Methods

Trying Some Experiments

Project 6 Number Guessing

Organizing a New Project

Planning the Project

Looking at the Program Skeleton

Creating Placeholder Classes

Creating an empty Game class

Creating an empty Player class

Adding the missing initialize to the Game class

Adding Player Methods

Creating player getter methods

Creating player setter methods

Adding player utility methods

Writing the Game Class Code

Coding the Game class getters

Setting up the round

Running the guessing loop

Adding the hint code

Scoring the round

Showing the player the results

Trying Some Experiments

Part III Working with Lots of Your Own Data

Project 7 Short Straw

Organizing a New Project

Planning the Project

Looking at the Program Skeleton

Creating Placeholder Classes

Creating an empty Game class

Creating an empty Player class

Creating an empty Straw class

Coding the Straw Methods

Creating straw getter methods

Creating the straw factory method

An array primer

Coding the Player Methods

Creating player getters and setters

Creating player helper methods

Coding Game Methods

Code initialization and the end condition

Code user interface methods

Coding the main game logic methods

Trying Some Experiments

Project 8 Code Breaker

Organizing a New Project

Planning the Project

Seeing how the Caesar cipher works

Looking at the program skeleton

Creating Placeholder Classes

The CodeBreaker class

The Caesar class

Coding CodeBreaker Methods

The CodeBreaker run method

User interface methods

Encryption and decryption methods

Coding Caesar Methods

Setup methods

A hash primer

Encryption and decryption methods

Trying Some Experiments

Project 9 Acey Deucey

Organizing a New Project

Planning the Project

Looking at the Program Skeleton

Creating Classes

Creating the card class

Creating the deck class

Creating the player class

Creating the Game class

Trying Some Experiments

Part IV Using Shared Code to Get Graphical

Project 10 A‐maze‐ing

Organizing a New Project

Planning the Project

Looking at the Program Skeleton

Creating Placeholder Classes

The Game class

The Level class

The Tile class

The Player class

Coding Amazing Methods

Coding Game Methods

Coding Level Methods

Coding Tile Methods

Coding Player Methods

Trying Some Experiments

Project 11 Tower

Organizing a New Project

Planning the Project

Looking at the Program Skeleton

Creating Placeholder Classes

The Game class

The Post class

The Disc class

Coding Post Methods

Coding Disc Methods

Coding Game Methods

Trying Some Experiments

Project 12 Game of Life

Organizing a New Project

Planning the Project

Looking at the Program Skeleton

Creating Placeholder Classes

The Game class

The Grid class

The Cell class

Coding Cell Methods

Coding Grid Methods

Coding Game Methods

Programming the user interface

Writing the game rules

Adding more seed patterns

Trying Some Experiments

Index

EULA

The users who browse this book also browse


No browse record.