# Create commands each of the text aligned horizontally?

I am using exam document class as my guide in creating my own documentclass but i have encountered a problem.How will i create a command for each of the four texts in a line. here is a sample image:

.

the command names that will be created would include commands for each: time, ExamCategory, MaximumMarks, and PassingScore. these when used, will be displayed in one line or horizontally aligned as what was indicated in the image.

-

Text will align itself to the current baseline by default so you don't need to do anything.

\def\time#1{\def\xtime{#1}}
\def\ExamCategory#1{\def\xExamCategory{#1}}
\def\MaximumMarks#1{\def\xMaximumMarks{#1}}
\def\PassingScore#1{\def\xPassingScore{#1}}

\time{1 hour}
\ExamCategory{Humanities prelim}
\MaximumMarks{50}
\PassingScore{30}

\noindent\makebox[\textwidth]{Time: \xtime%

Wouldn't \makebox[\textwidth][s]{...} (with \hfil instead of \quad) be a valid alternative? –  egreg Mar 11 '13 at 16:42
@DavidCarlisle: how should I insert this in the class.. I am currently typing on my .tex file this long text argument:: \noindent \uline{Time: 1 hour \hfill\hfill\normalsize\emph{\underline{ Humanities II preliminary Exam }} \hfill \hfill Maximum Marks: 50 \hfill \hfill Passing score: 30} \hfill \hfill \hfill but when the four command will be created, then i will just type: \time{4} \subject{Humanities II Preliminary} \marks{50} \passScore{30} something like this.. but how to create the command for this? –  Kayla Mar 12 '13 at 8:03