تبلیغات

آشنایی با Ruby Collections

دسته بندی ها: آموزش روبی (Ruby) ، آموزش های TreeHouse

در این دوره با collections در روبی، ساختارهای داده برای ایجاد collections در روبی: آرایه ها و هش ها و نوشتن برنامه های ساده روبی آشنا می شوید.

سرفصل:

  • آرایه های روبی
  • ایجاد یک آرایه
  • اضافه کردن آیتم ها به آرایه ها
  • دسترسی به آیتم ها در آرایه ها
  • حذف آیتم ها از آرایه ها
  • هش های روبی
  • ایجاد Ruby Hash
  • کار با کلید های هش
  • کار با ارزش هاش
  • متدهای هش
  • ساخت یک برنامه فهرست خواربار
  • ساخت یک برنامه فهرست خواربار: قسمت 1
  • ایجاد یک متد که هش را بازگرداند
  • ساخت یک برنامه فهرست خواربار: قسمت 2
  • ایجاد یک متد که آرایه را بازگرداند
  • ساخت یک برنامه فهرست خواربار: قسمت 3
  • بازگشت های متد با Hashes و Arrays
  • ساخت یک برنامه فهرست خواربار: قسمت 4
  • کار با هش ها که حاوی آرایه ها است
آیا این نوشته را دوست داشتید؟
Ruby Collections Course Publisher:TeamTreeHouse Author:Jason Seifer Level:Beginner

In the Ruby Collections course at Treehouse, you'll level up your Ruby knowledge and start learning about collections. We use two basic data structures to create collections in Ruby: arrays and hashes. These are both examples of
About this Course
In the Ruby Collections course at Treehouse, you'll level up your Ruby knowledge and start learning about collections. We use two basic data structures to create collections in Ruby: arrays and hashes. These are both examples of "collections" and you’ll work with them a lot in your career as a Ruby programmer. During the course, we'll be writing simple programs that build on what we learned in this course and in previous courses.
What you'll learn
Ruby Arrays
Ruby Hashes
Ruby CollectionsRuby Arrays
An array is a container of data, similar to a list. Arrays can be used to store many different kinds of data including strings, numbers, and almost any other kind of Ruby object. In this stage, we'll learn how to create and manipulate arrays.
8 steps
Ruby Arrays
5:03
Creating an Array
1 objective
Adding Items to Arrays
3:26
Adding Items to Arrays
2 objectives
Accessing Items in Arrays
4:42
Accessing Items in Arrays
3 objectives
Removing Items From Arrays
3:43
Removing Items From Arrays
2 objectives
Ruby Hashes
A hash is data structure similar to an array. Hashes are used all throughout Ruby programs. In this stage, we'll get comfortable creating and working with hashes in Ruby.
8 steps
Ruby Hash Creation
6:35
Ruby Hash Creation
2 objectives
Working with Hash Keys
4:28
Working with Hash Keys
1 objective
Working with Hash Values
2:00
Working with Hash Values
2 objectives
Hash Methods
6:52
Hash Methods
1 objective
Build a Grocery List Program
Now that we know how to use arrays and hashes, we're going to build a small program that makes a grocery list for us. We'll combine all of the knowledge we've learned so far including input and output, method definitions, and more.
9 steps
Build a Grocery List Program: Part 1
3:15
Create a Method That Returns a Hash
1 objective
Build a Grocery List Program: Part 2
3:58
Create a Method That Returns an Array
1 objective
Build a Grocery List Program: Part 3
3:47
Method Returns with Hashes and Arrays
1 objective
Build a Grocery List Program: Part 4
4:17
Working with Hashes That Contain Arrays
1 objective
Ruby Collections: Review
6 questions
Extra Credit
On your own, research how to use loops and modify our grocery list program to continually ask for input rather than only ask for three different items.

پیشنهاد فرادرس

لینک های دانلود حجم فایل: 87.0MB TeamTreeHouse Ruby Collections Course_git.ir.rar