Julia Tutorial
Julia is an open-source programming language licensed under the MIT License, available for free use by everyone.
Julia is a high-performance dynamic programming language designed for scientific computing.
Initially developed to meet the needs of high-performance numerical analysis and computational science, Julia does not require an interpreter and is fast.
Julia was first released in 2012 and supports various platforms: macOS, Windows, Linux, FreeBSD, Android.
Features of the Julia Language
- The core language is very small, with the standard library written in Julia itself.
- It calls many other mature high-performance foundational codes, such as linear algebra, random number generation, fast Fourier transform, and string processing.
- Rich syntax for creating or describing objects.
- High performance, close to statically compiled languages, including user-defined types.
- Designed for parallel and distributed computing.
- Lightweight coroutines.
- Elegant and extensible type conversion/promotion.
- Supports Unicode, including but not limited to UTF-8.
- Directly calls C functions (no wrappers or special APIs required).
- Shell-like process management capabilities.
- Lisp-like macros and other metaprogramming tools.
- Can be used with Jupyter notebook.
Uses of the Julia Language
Julia is primarily used for numerical computation.
First Julia Program
Next, let's write our first Julia program, hello.jl (Julia file extension .jl
), with the following code:
hello.jl File
println("Hello World!")
To execute Julia code, use the julia hello.jl
command.
Executing the above code outputs:
$ julia hello.jl
Hello, World!
Reference Links
Julia Official Website: https://julialang.org/
Julia Chinese Manual: https://docs.juliacn.com/latest/