report.fun 790 B

12345678910111213141516171819
  1. #import std
  2. #import nat
  3. #import flo
  4. #executable (<'param'>,<'employees.txt','clients.txt','billrates.txt'>)
  5. report = ~&iNC+ -+
  6. file$[stamp: &!,contents: 'rrr'%=*'lll'+ --<''>,path: <'report.tex'>!],
  7. ~command.files; ^H\~&z.contents -+
  8. <"e","c","b">. tbl-sectioned_table2+ -+
  9. //~& ~&iNCNVS <'Client','Employee','Date','Hours','Fee'>,
  10. * ^lrNCT/~&y ~&z; ~&t?\~& ^lrNCT/~& plus:-0.,
  11. ~&htNtCSPCK7S+ * *= ~&hthNttPCCSPC+ * ^/"c"+~&h :^/"e"+~&th :^(
  12. take/6+ ~&tttt+ stt-time_to_string+ %np+ ~&tthNC,
  13. ^lrNCC(~&r,times)^(
  14. %ep+ ~&iNC+ "b"+ ~&th,
  15. div\3.6e3+ float+ difference+~&thPhX+ %np*+ ~&ttiNCS)),
  16. |=hK2SthPhttPCCSSS&th+ sep` *+ ~&F+-,
  17. ~&y; * ~contents.&F; -:+ * sep` ; :^|/~& mat` +-+-