Skip to main content
deleted 147 characters in body
Source Link

LATEX 239239 226

The byte count does not include the \documentclass command nor any \usepackage commands. I would argue both count as using external packages, as the former includes definitions in an external .cls file, and usepackage is practically synonymous with an include statement. Output is a pdf file containing the 100 lines with no other text, formatted appropriately. Try it at writelatex.com!Try it at writelatex.com!

\begin{document}\newcounter{a}\def\c{re a time }\def\d{een-hundreds we\c}\StrLen{\d}[\b]\forloop{a}{\parindent}{\value{a}<\b}{The eight\d for rum.\\The ninet\d for fun.\\The two-thousands a\c to run\\a civilized classroom.\\}\end{document}\begin{document}\newcounter=\def\_{re a time }\def\-{een-hundreds we\_}\StrLen\-[\b]\forloop=\parindent{\value=<\b}{The eight\-for rum.\\The ninet\-for fun.\\The two-thousands a\_to run\\a civilized classroom.\\}\end{document}

Ungolfed:

\documentclass{letter}

\usepackage{forloop}
\usepackage{parskip}
\usepackage{xstring}
\usepackage{nopageno}

\begin{document}

\newcounter{a}\newcounter=

\def\c\def\_{re a time }
\def\d\def\-{een-hundreds we\cwe\_}
 
% Sets \b to be the length of \d, in characters, when fully expanded
\StrLen{\d}\StrLen\-[\b]

% Loops over a from \parindent to \b
% Note that parskip package sets \parindent to 0
% and \b is 25 from the length of \d fully expanded
\forloop{a}{\parindent}{\value\forloop=\parindent{a}<\b\value=<\b}{ 

    The eight\d eight\-for rum.\\
    The ninet\d ninet\-for fun.\\
    The two-thousands a\c toa\_to run\\
    a civilized classroom.\\ 

}

\end{document}

Edit: New and improved. Also made link go to read-only version of code. Thank you Dennis!

LATEX 239

The byte count does not include the \documentclass command nor any \usepackage commands. I would argue both count as using external packages, as the former includes definitions in an external .cls file, and usepackage is practically synonymous with an include statement. Output is a pdf file containing the 100 lines with no other text, formatted appropriately. Try it at writelatex.com!

\begin{document}\newcounter{a}\def\c{re a time }\def\d{een-hundreds we\c}\StrLen{\d}[\b]\forloop{a}{\parindent}{\value{a}<\b}{The eight\d for rum.\\The ninet\d for fun.\\The two-thousands a\c to run\\a civilized classroom.\\}\end{document}

Ungolfed:

\documentclass{letter}

\usepackage{forloop}
\usepackage{parskip}
\usepackage{xstring}
\usepackage{nopageno}

\begin{document}

\newcounter{a}

\def\c{re a time }
\def\d{een-hundreds we\c}
 
% Sets \b to be the length of \d, in characters, when fully expanded
\StrLen{\d}[\b]

% Loops over a from \parindent to \b
% Note that parskip package sets \parindent to 0
% and \b is 25 from the length of \d fully expanded
\forloop{a}{\parindent}{\value{a}<\b}{
    The eight\d for rum.\\
    The ninet\d for fun.\\
    The two-thousands a\c to run\\
    a civilized classroom.\\
}

\end{document}

LATEX 239 226

The byte count does not include the \documentclass command nor any \usepackage commands. I would argue both count as using external packages, as the former includes definitions in an external .cls file, and usepackage is practically synonymous with an include statement. Output is a pdf file containing the 100 lines with no other text, formatted appropriately. Try it at writelatex.com!

\begin{document}\newcounter=\def\_{re a time }\def\-{een-hundreds we\_}\StrLen\-[\b]\forloop=\parindent{\value=<\b}{The eight\-for rum.\\The ninet\-for fun.\\The two-thousands a\_to run\\a civilized classroom.\\}\end{document}

Ungolfed:

\documentclass{letter}

\usepackage{forloop}
\usepackage{parskip}
\usepackage{xstring}
\usepackage{nopageno}

\begin{document}

\newcounter=

\def\_{re a time }
\def\-{een-hundreds we\_}

\StrLen\-[\b]

\forloop=\parindent{\value=<\b}{ 

    The eight\-for rum.\\
    The ninet\-for fun.\\
    The two-thousands a\_to run\\
    a civilized classroom.\\ 

}

\end{document}

Edit: New and improved. Also made link go to read-only version of code. Thank you Dennis!

Source Link

LATEX 239

The byte count does not include the \documentclass command nor any \usepackage commands. I would argue both count as using external packages, as the former includes definitions in an external .cls file, and usepackage is practically synonymous with an include statement. Output is a pdf file containing the 100 lines with no other text, formatted appropriately. Try it at writelatex.com!

\begin{document}\newcounter{a}\def\c{re a time }\def\d{een-hundreds we\c}\StrLen{\d}[\b]\forloop{a}{\parindent}{\value{a}<\b}{The eight\d for rum.\\The ninet\d for fun.\\The two-thousands a\c to run\\a civilized classroom.\\}\end{document}

Ungolfed:

\documentclass{letter}

\usepackage{forloop}
\usepackage{parskip}
\usepackage{xstring}
\usepackage{nopageno}

\begin{document}

\newcounter{a}

\def\c{re a time }
\def\d{een-hundreds we\c}

% Sets \b to be the length of \d, in characters, when fully expanded
\StrLen{\d}[\b]

% Loops over a from \parindent to \b
% Note that parskip package sets \parindent to 0
% and \b is 25 from the length of \d fully expanded
\forloop{a}{\parindent}{\value{a}<\b}{
    The eight\d for rum.\\
    The ninet\d for fun.\\
    The two-thousands a\c to run\\
    a civilized classroom.\\
}

\end{document}