0

I am trying to build a routine to return a HTML table formatted like the one bellow in java. The table is entirely build with characters and mono-spaced fonts. The routine must calculate the number of letters and spaces needed to write all the horizontal and vertical lines.

This sort of algorithm is also embedded in MySQL console, but I still have not found any basic model in internet about how to build it.

I know I could spend a couple of days building the algorithm, but I am almost sure that somebody has done this before, so if anybody can help me with this I would really appreciate it.

+--------+--------------+    +-----------------+-----------+--------------+
| id     | title        |    | url             | price ($) |  product_id  |
+--------+--------------+    +-----------------+-----------+--------------+
|  1     | Test product |    | http://test/    |      10.0 |  1           |
+--------+--------------+    +-----------------+-----------+--------------+
Nagaraj S
  • 13,316
  • 6
  • 32
  • 53
Joe Almore
  • 4,036
  • 9
  • 52
  • 77

0 Answers0