# pdflatex error: Missing \begin{document}

I have a settings.tex file that looks like this:

\documentclass{letterpaper, 12pt, amsart}
\usepackage{ifthen}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{tikz}


And I file test.tex that looks like:

\input{settings.tex}
\begin{document}
hi
\end{document}


When I run pdflatex test.tex I get an error saying I am missing \begin{document}. What gives?

• Your documentclass is the problem. letterpaper and 12pt are optional arguments and should go in [], so you need \documentclass[letterpaper,12pt]{amsart} – Henk Metselaar May 10 '19 at 2:27
• Thanks, godbless. – mtheorylord May 10 '19 at 2:34
• @HenkMetselaar Could you put your comment as an answer? This indeed seems to be the solution to the problem! – Herthog May 10 '19 at 9:40

Your documentclass is the problem. letterpaper and 12pt are optional arguments and should go in [], so you need \documentclass[letterpaper,12pt]{amsart}