Introduction to the Odin Programming Language. It aims to be a modern alternative to C, addressing its limitations and providing additional features. It supports compiled, manually managed, statically typed code, making it suitable for systems programming and game development. The article covers topics such as installation, basic syntax, variables, loops, control flow, data structures, manual memory management, and more.

45m read timeFrom zylinski.se
Post cover image
Table of contents
Preface #A note on learning Odin #Installing Odin #Basic “Hello World” #Variables and constants #Loops #Procedure parameters and return values #If statements #Array basics, swizzling and array programming #Structs #Enums and switch #Unions #Pointers and passing proc parameters by pointer/value/reference #Dynamic arrays #Slices: A window into a part of an array #Enumerated arrays #defer: Making things happen at end of scope #when: Compile-time check to enable/disable code #Implicit context and custom allocators #Parametric polymorphism: Reusable, generic procedures #Getting comfy with manual memory management #Strings #Package system and code organization #Finding your way around core (the standard library) #Where to find more Odin resources #Thanks for reading! #
6 Comments

Sort: