## LaTeX forum ⇒ Text Formatting ⇒ Two columns, both left justified

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
Bakster
Posts: 2
Joined: Sun Dec 05, 2010 2:27 am

### Two columns, both left justified

I want two addresses on the same lines, one on the left and one on the right. I achieved this with:

\noindent \textbf{Home Address} \hfill \textbf{Term Address} \\Address Line 1 \hfill Address Line 1 \\Address Line 2 \hfill Address Line 2 \\Address Line 3 \hfill  Address Line 3 \\Postcode \hfill Postcode \\

However, the address on the right of the page is right justified, and I want it to be left justified (within its own 'block' on the right hand side of the page). Is there a simple modification I can make to achieve this, or do I require a more substantial solution such as creating a table?

I tried creating a table but couldn't get it to work, one reason being that the table is indented and I don't know how to align it to the left margin (there were a few other problems too).

Any help is much appreciated!
Last edited by Bakster on Wed Mar 16, 2011 2:39 pm, edited 1 time in total.

gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm
Hi,

as you suspected, a table is the solution:

\documentclass{article} \newlength\mylena\newlength\mylenb\setlength\mylena{\linewidth}\settowidth\mylenb{\textbf{Term Address}}\addtolength\mylena{-2\mylenb} \begin{document} text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text \noindent\begin{tabular*}{\linewidth}{@{}l@{\hspace{.5\mylena}}l}   \textbf{Home Address} & \textbf{Term Address} \\    Address Line 1 & Address Line 1 \\   Address Line 2 & Address Line 2 \\   Address Line 3 &  Address Line 3 \\   Postcode & Postcode\end{tabular*} \end{document}
1,1,2,3,5,8,13,21,34,55,89,144,233,...

Bakster
Posts: 2
Joined: Sun Dec 05, 2010 2:27 am
That's great, thank you!

localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm
Bakster wrote:That's great […]

Then please mark the topic (not the last post) accordingly as written in Section 3 of the Board Rules (to be read before posting).

Best regards and welcome to the board
Thorsten
LaTeX Community Moderator

¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1