\section{Question 1}
\begin{figure}
\centering
\includegraphics[width=\linewidth]{Cute Goat In Pink.jpg}
\caption{Daredevil}
\label{fig:my_label}
\end{figure}
Above is the code I am trying to use but for some reason, it is not showing up on the compiled pdf.
So, I am using the online version of overleaf so I don't think the issue is with my version. Also, below is the entire code I am currently using:
\documentclass{article}
\usepackage{graphicx} % Required for inserting images
\title{CPSC}
\author{}
\date{July 2023}
\begin{document}
\maketitle
\section{Question 1}
Hello
\begin{figure}
\centering
\includegraphics[width=\linewidth]{Cute Goat In Pink.jpg}
\caption{Daredevil}
\label{fig:my_label}
\end{figure}
Goodbye
\end{document}
Unfortunately, the only thing showing up is hello and goodbye. As for the picture name, that is how it is saved. I tried replacing it with another one that is in all small letters with no spaces and still had the same issues. The log files in the pdf are showing absolutely no errors which is making me even more confused. And I copied this code directly from Overleaf so theoretically, it should work.

logfile? Does it work using a replacement image likeexample-image.png? How do you compile? Are you using pdflatex or something like latex + dvips + ps2pdf? Can you please extend your code to a minimal working example, that can be used to reproduce your issue? If it does work with an replacement image, we would also need the problematic image file. Maybe it is broken or the filename is not absolutely correct. – cabohah Jul 30 '23 at 07:03graphics/graphicxpackage should not have problems with spaces in filenames. – cabohah Jul 30 '23 at 07:06example-image.png(as already recommended), the image and the caption are shown at page 2. If your image is also quite large, you should have a look if it is also moved to the next page. – cabohah Jul 30 '23 at 07:27