0Pricing
Elixir & Phoenix: Scalable Backend Development · レッスン

Elixir言語入門

Elixirの理念、Erlang/OTPとの関係を理解し、開発環境を構築します。

「Elixir言語入門」はCoddyKit上の無料Elixir & Phoenix: Scalable Backend Developmentレッスンです。 これはレッスン1/4です。 下記で完全なレッスンを無料で読むことができます。その後、ブラウザ内の組み込みコードエディタと24時間対応のAIチューターでハンズオン演習できます。 これはElixir & Phoenix: Scalable Backend Development学習パスの一部であり、ウェブとCoddyKitアプリ全体で進捗が同期されます。 Elixir & Phoenix: Scalable Backend Developmentコースには全4レッスンが含まれています。

このレッスンの一部はまだ翻訳されておらず、英語で表示されています。

Welcome to Elixir!

Elixir is a dynamic, functional language for scalable, maintainable apps. It runs on the battle-tested Erlang VM. Welcome aboard!

Why Choose Elixir?

You pick Elixir for effortless concurrency, fault tolerance that recovers gracefully, and a modern, productive syntax. Great for web, embedded, and real-time.

Erlang VM (BEAM) & OTP

Elixir runs on the Erlang VM (BEAM), famous for uptime, and uses OTP libraries to build fault-tolerant, distributed systems.

Getting Started: The Interactive Shell

The fastest way to play with Elixir is iex, its interactive shell. Just type iex in your terminal and start experimenting.

Your First Elixir Output

Time for Hello World. You print to the console with IO.puts — here it is inside a runnable module.

defmodule Greeter do
  def say_hello do
    IO.puts "Hello, CoddyKit!"
  end
end

Greeter.say_hello()

Basic Arithmetic

Elixir does arithmetic exactly as you would expect: add, subtract, multiply, divide. Run this to see basic math at work.

defmodule Calculator do
  def do_math do
    sum = 5 + 3
    product = 4 * 2
    IO.puts "Sum: #{sum}"
    IO.puts "Product: #{product}"
  end
end

Calculator.do_math()

Variables (Bindings) in Elixir

In Elixir, = binds a value to a variable. Variables are immutable — re-binding just creates a new binding, it never mutates the old value.

defmodule BindingsDemo do
  def show_bindings do
    name = "Elixir"
    IO.puts "First name: #{name}"

    # Re-binding 'name' creates a new binding
    name = "Phoenix"
    IO.puts "New name: #{name}"
    # The original "Elixir" value remains unchanged elsewhere
  end
end

BindingsDemo.show_bindings()

Atoms: Unique Constants

An atom is a constant whose value is its own name, written with a leading colon like :ok. Perfect as fast, clear identifiers and keys.

Elixir's Core Philosophy

Elixir is built on functional programming and concurrency — predictable code that easily runs many tasks at once across all your cores.

Quick Check: Elixir Foundations

Let's test your understanding of Elixir's core concepts.

Recap: Your Elixir Journey Begins!

You shipped your first Elixir skills: the BEAM and OTP, the iex shell, basic output and math, immutable bindings, and atoms. On to the good stuff!

よくある質問

「Elixir言語入門」レッスンは無料ですか?

はい。「Elixir言語入門」の完全なテキストはこのウェブで無料で読めます。インタラクティブに演習し(組み込みコードエディタと24時間対応のAIチューター)、Elixir & Phoenix: Scalable Backend Developmentコースの残りをアンロックするには、CoddyKit PROにアップグレードしてください。 Elixir & Phoenix: Scalable Backend Developmentコースには全4レッスンが含まれています。

「Elixir言語入門」で何を学びますか?

Elixirの理念、Erlang/OTPとの関係を理解し、開発環境を構築します。 ブラウザで直接実行するハンズオンコードでElixir & Phoenix: Scalable Backend Developmentを演習し、24時間対応のAIチューターがレッスンを進める中での質問に答えます。

Elixir & Phoenix: Scalable Backend Developmentを始めるのに経験は必要ですか?

事前経験は必要ありません。CoddyKitのElixir & Phoenix: Scalable Backend Developmentは初級者から上級者向けに構成されているため、ここから始めるか最初から始めて、自分のペースで進むことができます。 これはレッスン1/4です。

「Elixir言語入門」レッスンにはどのくらい時間がかかりますか?

ほとんどのCoddyKitレッスンは約5~10分かかります。各レッスンはコンパクトでインタラクティブなので、着実に進歩し、ウェブとアプリ全体で正確に前回の場所から再開できます。

このElixir & Phoenix: Scalable Backend Developmentレッスンでコードを書いて実行できますか?

はい。すべてのElixir & Phoenix: Scalable Backend Developmentレッスンに組み込みコードエディタが含まれているため、ブラウザでリアルコードを書いて実行し、即座のAIフィードバックを取得できます。ローカル設定は不要です。

このコースのすべてのレッスン

  1. Elixir言語入門
  2. 基本的なデータ型と演算子
  3. パターンマッチングと制御フロー
  4. Elixirの文字列、バイナリ、シジル
← Elixir & Phoenix: Scalable Backend Developmentに戻る