0

Here is my code:

\chapter{What Is Artificial Intelligence?}

\href{https://en.wikipedia.org/wiki/Artificial_intelligence}{Artificial intelligence} has become a very essential aspect of our life, from self-driving cars to robots that perform daily activities for us. Artificial intelligence, or AI, is an area of \href{https://en.wikipedia.org/wiki/Computer_science}{computer science} that deals with people being able to build intelligent computers capable of performing tasks that would normally need human intelligence. Companies such as Apple, Ford, and Tesla are moving toward a more AI-based approach to problem-solving, as well as attempting to integrate robots into their factories that could potentially replace humans in the next 30 to 40 years. Although, in a nutshell, this may appear to be a broad subject, you may wonder how humans are able to create AI models.

\begin{figure} \includegraphics[width=\linewidth]{Alan_Turing_Bilal_Rashid/bbbb.jpg} \caption{A boat.} \label{fig:boat1} \end{figure}

\begin{center} \textbf{Machine Learning} \href{https://en.wikipedia.org/wiki/Machine_learning}{Machine learning} is a branch of artificial intelligence and computer science, which uses datasets and mathematical algorithms to make decisions and identify patterns using very little human intervention. Below are three very common machine learning algorithms that help train a machine learning model. \end{center}

I don't know why the picture is coming after the "Machine Learning" block, can anyone help me solve this? Here is a pic for reference: enter image description here

David Carlisle
  • 757,742
  • 1
    you surrounded includegraphics with begin{figure} the purpose of figure is to mark it as a float that is taken out of the main document flow and may be re-inserted elsewhere depending on page breaking. use \begin{figure}[htbp] to tell latex it may use h to leave it in the same place if possible – David Carlisle Dec 11 '21 at 21:31
  • @DavidCarlisle Yea that works I was able to fix it Thank you so much! – Bilal Rashid Dec 11 '21 at 21:53
  • well as I say it isn't really a problem that needs fixing, the only thing figure does is allow it to move, so it moving is just the natural behaviour not something that should be fixed but see https://tex.stackexchange.com/questions/8625/force-figure-placement-in-text – David Carlisle Dec 11 '21 at 21:57
  • @DavidCarlisle it does answer my question thank you! – Bilal Rashid Dec 11 '21 at 22:03

0 Answers0