S9 (language)/Using External Functions: Difference between revisions
From Wiki**3
< S9 (language)
(New page: Exemplo da utilização das funções noutro ficheiro: <c> use int argc(); use string argv(int n); use int ackermann(int m, int n); use int getcnt(); public int s9() -> 0 { int m = 0; ...) |
No edit summary |
||
Line 18: | Line 18: | ||
</c> | </c> | ||
[[category: | [[category:Compiladores]] | ||
[[category: | [[category:Ensino]] |
Revision as of 14:32, 6 April 2015
Exemplo da utilização das funções noutro ficheiro:
<c> use int argc(); use string argv(int n); use int ackermann(int m, int n); use int getcnt();
public int s9() -> 0 {
int m = 0; int n = 0; "Teste para a função de Ackermann\n"! "Introduza M (<3): "! m = @; "Introduza N (<5): "! n = @; "Valor de ackermann("! m! ", "! n! "): "! ackermann(m, n)! "\n"! "Calls to ackermann: "! getcnt()! "\n"!
} </c>