เส้นทางการเรียนรู้

พื้นฐาน Rust

ตั้งแต่โปรแกรมแรกไปจนถึงตัวแปร ชนิดข้อมูล เงื่อนไข ลูป สตริง เวกเตอร์ และฟังก์ชัน พร้อมโจทย์หลังจบแต่ละหัวข้อ

บทเรียน 17 บท · โจทย์ 31 ข้อ

1 เริ่มต้น บทเรียน 5 บท

  1. บทเรียน โจทย์ 2 ข้อ Hello World and Program Structure Write your first Rust program and learn what fn main and println! do.
  2. บทเรียน โจทย์ 2 ข้อ Variables and Mutability Declare variables with let, allow changes with mut, and use constants and shadowing.
  3. บทเรียน โจทย์ 2 ข้อ Data Types Work with integers, floating-point numbers, booleans and characters, and convert between them.
  4. บทเรียน โจทย์ 2 ข้อ Operators and Arithmetic Use arithmetic, comparison and logical operators, and see how integer division works.
  5. บทเรียน โจทย์ 2 ข้อ Reading User Input Read a line from the keyboard and turn it into a number safely.

2 การตัดสินใจ บทเรียน 2 บท

  1. บทเรียน โจทย์ 2 ข้อ Conditions with if and else Choose what runs with if, else if and else, and use if as an expression.
  2. บทเรียน โจทย์ 1 ข้อ FizzBuzz Solve the classic FizzBuzz problem with match on a tuple.

3 ลูป บทเรียน 2 บท

  1. บทเรียน โจทย์ 2 ข้อ Loops: for, while and loop Repeat code with for over a range, while with a condition, and loop with break.
  2. บทเรียน โจทย์ 2 ข้อ Prime Numbers Check whether a number is prime and list the primes up to 30.

4 สตริงและข้อความ บทเรียน 2 บท

  1. บทเรียน โจทย์ 2 ข้อ Strings: String and &str Create, grow, search and split text with Rust's two string types.
  2. บทเรียน โจทย์ 1 ข้อ Reverse a String Reverse the characters of a string and the words of a sentence.

5 คอลเลกชัน บทเรียน 3 บท

  1. บทเรียน โจทย์ 2 ข้อ Tuples and Arrays Group values with tuples and store a fixed number of items in an array.
  2. บทเรียน โจทย์ 2 ข้อ Vectors Store a growing list of values in a Vec and read items safely.
  3. บทเรียน โจทย์ 2 ข้อ Fibonacci Sequence Generate Fibonacci numbers with a loop and a vector.

6 ฟังก์ชัน บทเรียน 2 บท

  1. บทเรียน โจทย์ 2 ข้อ Functions and Return Values Define functions with typed parameters and return values.
  2. บทเรียน โจทย์ 2 ข้อ Binary Search Find a value in a sorted slice by halving the search range.

7 ออบเจกต์และคลาส บทเรียน 1 บท

  1. บทเรียน โจทย์ 1 ข้อ Structs Group related values into your own type with named fields.
เรียนต่อ: พื้นฐานการเขียนโปรแกรม