Kara (programming environment)

from Wikipedia, the free encyclopedia
Kara

logo
Ladybug

Kara, a ladybug in a 2D world
Basic data

developer Raimond Reichert
Current  version versionless
(February 27, 2007)
operating system Windows , Linux , macOS , etc. v. m.
category Programming - learning environment
License Freeware
German speaking Yes
www.swisseduc.ch

Kara is a widespread educational software for a playful introduction to programming . Kara is based on the concept of finite automata and can be assigned to the so-called mini - languages .

Kara is a programmable ladybug who lives in a simple graphic world and has to solve tasks of varying difficulty, for example collecting shamrocks or finding the way through a labyrinth .

In addition to the version with a graphic program editor, there are also versions that can form the transition to real programming languages, such as Java , Ruby or Python , as well as environments on special topics, such as Turing machines .

All Java-enabled platforms (from J2SE , at least the J RE , for JavaKara even the J SDK ) support Kara.

history

A first version of Kara was created from 1999 to 2003 at the ETH Zurich with the participation of Jürg Nievergelt, Werner Hartmann , Raimond Reichert, Markus Brändle, Tobias Schlatter, with contributions by Philipp Boksberger, Horst Gierhardt, Reto Lamprecht, Remo Meier, Horst Müller , Nicole Völki, Samuel Zürcher. Today, Kara is continuously being developed by Raimond Reichert.

Prices

In 2000, Kara won the Fritz Kutter Prize for the promotion of practice- related computer science with the title “A playful introduction to programming: Kara, the programmable ladybug”, as Raimond Reichert's diploma thesis .

In 2002 he won with KaraToJava the European Academic Software Award in the category "Computer science" ( Engl. For computer science ).

Versions

All Kara versions and derivatives

When starting Kara, the environment can be selected. Depending on the situation, the entire world, the program window and the help are loaded. The selection cannot be changed while the program is running, but Kara can be instantiated multiple times .


The Kara world window

The integrated development environment always provides at least one self-generated world as well as a possibility to let Kara act automatically .

Kara herself is a ladybug in a two-dimensional world , along with tree stumps , toadstools and shamrocks. Shamrocks can be crossed, picked up and put down. Mushrooms can only be moved. However, trees are firm and lead to the end of the program if Kara runs against them.

The Beetle is controlled either manually via buttons next to the world map or via a "program" that corresponds to the respective version.

When a Kara program is running, be it logically via states in the graphic Kara interface or with Java Kara, the speed can be regulated at any time and the calculation paused.

All versions always contain tasks of various degrees of difficulty, some downloads even have solutions.

Kara - programming with machines

The graphic program editor from Kara

Kara is the starting point for finite automaton theory . For the time being it can be tried out on simple worlds how Kara behaves in his world and can interact with it.

After worlds have been created as usual, Kara's reactions can be determined in a graphic program editor.

There is a starting point that the program initially jumps to. The first sensor tests are carried out from there. Different sensors such as “tree in front?” Or “cloverleaf below?” Can be Boolean checked and, depending on the result of the sensor, different actions can be carried out and changed to other states.

Environments for real programming languages

JavaKara - programming with Java

The JavaKara program editor with the standard program

JavaKara's world is structured in the same way as the conventional Kara, only programming is no longer done with the graphical user interface, but with Java . Kara can move around, perform actions and check its sensors as usual.

The Kara libraries kara, worldand toolsare implemented directly in the allkara.jarclass JavaKaraProgram. There is full access to common Java control structures and packages.

All JavaKara programs must follow a certain basic structure (and of course applicable Java rules) so that they are syntactically correct and can therefore be correctly interpreted.

 public class /*Dateiname*/ extends JavaKaraProgram {
    public void myProgram() {
       // Hauptprogramm
    }
 }

The program window also offers an integrated "development environment" (IDE) with automatic indentation and syntax highlighting as well as an integrated compilation option .

Main developer Raimond Reicher himself about JavaKara:

“[JavaKara] is very time dependent. Kara, on the other hand, is timeless and still up-to-date if one day Java is no longer up-to-date. "

RubyKara, PythonKara, JavaScriptKara

As for Java, there are now other versions of Kara for the programming languages Ruby , Python and JavaScript .

The usual control structures for the respective language are fully available. Unlike JavaKara, a certain "basic structure" is not necessary because of the simpler syntax of these languages. A very simple, complete program for RubyKara looks like: B. looks like this:

while (!kara.treeFront){  // Eine while-Schleife läuft solange wie der wert true ist, also wahr
//!kara.treeFront Bedeutet: Ist kein Baum vor mir
  kara.putLeaf();
if (kara.onLeaf()) //if (Bedingung) und
  kara.move();// die if-Abfrage zählt nur 1 Zeile darunter
}// ende der while-Schleife

Environments on specific topics

Kara derivatives use the same world as the normal Kara versions, but fundamentally change the actors and objects in it. They have less to do with the normal teaching aid Kara and sometimes require additional material or knowledge.

MultiKara - concurrent programming

MultiKara is very similar to Kara, but is more suitable for more advanced purposes and is mostly (for the time being) skipped if Kara is used as a learning environment.

In contrast to the normal Kara, up to four ladybugs can be used at the same time and programmed individually - still graphically.

Kara's world is supplemented by street symbols which restrict the accessibility of a field, as well as several synchronization mechanisms. For example, a ladybug can be blocked until all other ladybugs ( threads ) have reached a certain point in the program sequence or in the world.

You can also define your own sensors for the three fields around the ladybug (right, left, front) and your own. Shamrocks apply to each beetle individually.

TuringKara - Turing machines clearly

Kara's world Turing completely
red: reading head

TuringKara is a Turing-complete version of Kara and instead of the ladybird Kara offers a read and write head (only read head for short, compare hard disk ).

Instead of natural symbols, the world can be filled with ones and zeros , double cross or arrows . They behave like the shamrocks from Kara, so they are always under the reading head. There are no fixed functions for the individual symbols, for example the arrows can be interpreted as signposts in the world (similar to a punch card ) or as arithmetic operators.

Consequently, the reading head can no longer examine the three surrounding fields - like the ladybird in Kara - but only its current position. It is again programmed graphically with states and sensor tests.

LegoKara - Kara for Lego Mindstorms

Kara modifies its program output in LegoKara RCX- appropriate. The graphically written programs can be downloaded to the RCX.

The world offers only the ladybug (LegoKara), clover (light sensor) and tree stumps (pressure sensor), but three RCX functions are left turn , right turn and settings added.

Other versions

  • ScratchKara, a combination of the Scratch and Kara programming environments
  • GreenfootKara, an implementation of Kara in Greenfoot

See also

swell

  1. SwissEduc: Raimond Reichert
  2. Fritz-Kutter Fund: Former award winners ( Memento of the original from August 20, 2006 in the Internet Archive ) Info: The archive link was inserted automatically and has not yet been checked. Please check the original and archive link according to the instructions and then remove this notice. @1@ 2Template: Webachiv / IABot / www.kutter-fonds.ethz.ch
  3. EASA 2002: KaraToJava ( Memento from September 27, 2007 in the Internet Archive )

literature

Web links