20 lines
653 B
Text
20 lines
653 B
Text
Module Checkit {
|
|
Document a$, max_time$
|
|
Load.doc a$, "mlijobs.txt"
|
|
const dl$=" ", nl$={
|
|
}
|
|
Def long m, out, max_out=-1
|
|
m=Paragraph(a$, 0)
|
|
If Forward(a$,m) then {
|
|
While m {
|
|
job$=Paragraph$(a$,(m))
|
|
out+=If(Piece$(job$,dl$,2)="OUT"->1&, -1&)
|
|
If out>max_out then max_out=out : Clear max_time$
|
|
If out=max_out then max_time$=Piece$(job$,dl$,4)+nl$
|
|
}
|
|
}
|
|
Report Format$("Maximum simultaneous license use is {0} at the following times:",max_out)
|
|
Print " "; ' left margin
|
|
Report max_time$
|
|
}
|
|
Checkit
|