The following tutorials on Kaya are available and are intended to quickly outline the various parts of the Kaya language and where and why you might use them. They are not intended to teach you how to program from scratch - some experience of imperative programming (C, Perl, PHP, etc) in general is assumed. Please let us know if there's something you think is missed out or needs more detail.
The basic syntax of Kaya is described in the first four tutorials. The fifth tutorial contains details of web application writing - even if you intend to only use Kaya to write web applications, it's probably a good idea to at least glance at the first four to get the syntax clear, as most of it is as applicable to web applications as to normal programs.
- The basics: Using the compiler, basic Kaya syntax, short programs, functions and constants, built-in data types, exception handling.
- Data types: Algebraic data types, polymorphic data types, defining new data types, function overloading.
- Kaya modules: The Kaya module system, the standard library, writing modules, global variables.
- Using functions: Advanced function use, partial application, anonymous functions.
- Web programming: Writing web applications, state handling, security and 'rekey', images, CGI and webapp models, file uploads. (several tutorials in this section).
- Database access: Accessing SQL databases using the standard database interface.
- Testing programs: A preview of the unit-testing features coming in Kaya 0.5.2
- Foreign functions: Accessing C library functions from Kaya, writing glue libraries.
- Compiler options: Command-line options for kayac.
In addition to the tutorials, the library reference documents all functions in the Kaya standard library.
The following conventions are used in the Kaya tutorials (and elsewhere on the Kaya site)
- Text like
a = 5;represents program code. The style
expression;is used to represent a block of code with a particular purpose.
- Text like kayac hello.k represents sample input or typed commands.
- Text like Hello World! represents sample output.