1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
<!DOCTYPE html> <style> :root { border-collapse: collapse; border-spacing: 1px; } .cell { display: table-cell; border: solid black; } .pre { white-space: pre; border: solid blue; } .table { display: inline-table; } </style> <span class="pre"> <span class="table"><span class="cell">A</span> <span class="cell">B</span></span> </span>