|
Aldor is a programming language. It is the successor of A# as the extension language of the Axiom computer algebra system. The Aldor language combines imperative, functional, and object-oriented features. It has an elaborate type system, allowing types to be used as first-class values. Aldor's syntax is heavily influenced by Pascal, but it is optionally indentation-sensitive, like Python. In its current implementation, it is compiled, but an interactive listener is provided. Aldor is Free software, available under the Apache License. == Examples == The Hello world program looks like this: #include "aldor" #include "aldorio" stdout << "Hello, world!" << newline; Example of dependent types (from the User Guide): #include "aldor" #include "aldorio" #pile sumlist(R: ArithmeticType, l: List R): R == s: R := 0; for x in l repeat s := s + x s import from List Integer, Integer, List SingleFloat, SingleFloat stdout << sumlist(Integer, ()) << newline stdout << sumlist(SingleFloat, (2.1, 2.2, 2.4 )) << newline ;99 Bottles of Beer #include "aldor" #include "aldorio" import from Integer, String; bob(n: Integer): String == main(): () == main(); 抄文引用元・出典: フリー百科事典『 ウィキペディア(Wikipedia)』 ■ウィキペディアで「Aldor」の詳細全文を読む スポンサード リンク
|