Add tasks for all the new languages

This commit is contained in:
Tina Müller 2016-12-05 23:44:36 +01:00
parent 9dc3c2bb62
commit bba7bfd280
13208 changed files with 134745 additions and 0 deletions

View file

@ -0,0 +1,6 @@
function increment(integer i, integer inc=1)
return i+inc
end function
?increment(5) -- shows 6
?increment(5,2) -- shows 7

View file

@ -0,0 +1 @@
printf(1,"%d records sorted in %3.2s\n",{records,time()-t0})

View file

@ -0,0 +1,22 @@
integer sortcol = 0
integer sortdir = 1
function by_column(integer i, integer j)
return sortdir*compare(data[i][sortcol],data[j][sortcol])
end function
sequence tags = tagset(table_size) -- {1,2,..table_size}
function click_cb(Ihandle self, integer l, integer c, atom pStatus)
string sortc
...
sortc = sprintf("SORTSIGN%d",c)
sortdir = iff(IupGetAttribute(self,sortc)="DOWN"?-1:1)
IupSetAttribute(self,sortc,iff(sortdir=-1?"UP":"DOWN"))
sortcol = c
tags = custom_sort(routine_id("by_column"),tags)
function value_cb(Ihandle /*self*/, integer l, integer c)
l = tags[l]
return data[l][c]
end function