Complete function make_move_cpu
The cpu has to make a 'smart move'. So, when something of a ship is hitted earlier, the cpu has to shoot where the ship is most likely to be.

Could you elaborate what the code exactly does? It's not that easy to comprehend the logic here :)
For sure ;)
What I would like to do, is first making a random move (like everone does in the beginning of the game), and if it is a hit, save it and try the next time an adjacent field (1 up, down, right or left, random chose between these four). If the random chose was a good one (suppose right), you know there's a ship lying horizontal. So, keep trying right and left (not longer up and down), until the ship is sunk. If the ship is sunk, but there are also other hits (for example when two ships are located next to each other), search for the next ship. If there are no longer 'possibilities' (one or more hits on a non-sunked ship), start again with random shots.
I hope this makes some sense. :)
May I thank you very much for your input! I really appreciate it!
Randpy
Is the above code the code that you are working on? and it's not working?
This is what I would like that it’s doing, but I’m stuck...
Some help with this is therefore very welcome ;)
This is what I would like that it’s doing, but I’m stuck...
I started on my own fork, I made the structure a little more clearer and added some helper functions and constants.
The game logic you want to have (recognise patterns) could be very hard for beginners, especially when there are several unsunken ships hit. I will look at this problem later on, but I bet we can't be the only people who programmed a battleship CPU yet...
I know there's someone who has already made a CPU for a Battleship game.
I will take a small look at his code. It would also be very nice if you could help me a little further in your fork :)
Thanks again in advance!