Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
14
Task/Create-an-HTML-table/Nim/create-an-html-table.nim
Normal file
14
Task/Create-an-HTML-table/Nim/create-an-html-table.nim
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
import math, htmlgen
|
||||
randomize()
|
||||
|
||||
template randTD(): expr = td($random(1000..9999))
|
||||
proc randTR(x): auto =
|
||||
tr(td($x, style="font-weight: bold"), randTD, randTD, randTD)
|
||||
|
||||
echo table(
|
||||
tr(th"", th"X", th"Y", th"Z"),
|
||||
randTR 1,
|
||||
randTR 2,
|
||||
randTR 3,
|
||||
randTR 4,
|
||||
randTR 5)
|
||||
Loading…
Add table
Add a link
Reference in a new issue