2 local random = math
.random
3 math
.randomseed(os
.time())
6 table.insert(edges
, edge
{"n"..tostring(random(1,N
/2)), "n"..tostring(random(1,N
/2))})
9 if arg
[1] == "dot" then
10 return digraph
{"G", unpack(edges
)}
12 return ugraph
{"G", unpack(edges
)}