I am typing a some questions for a class and want to show the mark allocations in the same line with the text without using either minipage or flush right as below. How can I do this. Please help. Please check the commands below:
\documentclass[12pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage[left=2cm,right=2cm,top=2cm,bottom=2cm]{geometry}
\author{Misheck Diza}
\begin{document}
\begin{enumerate}
\item{For every investment venture to be successful one needs investment vehicle called an asset, compare and contrast real and financial asset\begin{flushright}
(10 marks)
\end{flushright}}
\item{State whether the following assets are either financial or real:
\begin{enumerate}
\item{Industrial Property\begin{flushright}
(2 marks)
\end{flushright}}
\item{Commercial Paper\begin{flushright}
(2 marks)
\end{flushright}}
\item{Comoran Stock\begin{flushright}
(2 marks)
\end{flushright}}
\item{Treasury Bills\begin{flushright}
(2 marks)
\end{flushright}}
\end{enumerate}}
\end{enumerate}
\end{document}
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
\documentclass{article}
\usepackage[margin=2cm]{geometry}
\begin{document}
\begin{enumerate}
\item For every investment venture to be successful one needs investment vehicle called an asset, compare and contrast real and financial asset\hfill
(10 marks)
\item State whether the following assets are either financial or real:
\begin{enumerate}
\item Industrial Property\hfill (2 marks)
\item Commercial Paper \hfill (2 marks)
\item Comoran Stock \hfill (2 marks)
\item Treasury Bills \hfill (2 marks)
\end{enumerate}
\end{enumerate}
\end{document}
Please note, that \item can take an optional argument, but does not have a mandatory argument.
I recommend looking at packages like exsheets or the exam class that are made for doing this job.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p