0

enter image description here when I try to make population I get this response. make*** no rule to make 'population'. stop.

The other runs fine it makes and runs the code

2 Answers 2

1

Your code has multiple errors. First, you declare two int variables named s. Second, you declare an int in your do-while loop without giving it a variable name. Second, you are using printf syntax in your get_int functions. Your do-while loop is also not written correctly. When I try to make your code, I get a number of errors. All of these will through errors that could prevent the compiler from making this. I do not know why you might not be given the errors in your terminal, but, when I correct these issues, the make command functions correctly.

Edit: I can see your problem in the new picture. Sorry, should've thought of having you spell out the directory, as Cliff did, but it didn't occur to me that this could be the issue. You appear have a leading space in the name of your population.c file, which is why it is surrounded in single quotes. You can either right-click on the name of the file in the file explorer to rename it without the space, or use your terminal to run the following commands cp ' population.c' population.c followed by rm ' population.c'.

1
  • the make command should have run and produced the compile errors. It didn't. I find this unusual. In the command window, please run ls -al to confirm that the source file is in the same directory. Otherwise, there might be an issue with the environment setup.
    – Cliff B
    Commented Jan 8, 2021 at 1:37
0

First thank you, Robert for helping as you can tell i know very little at this point. I ran ls -al this is the result.enter image description here

3
  • I have edited my answer to add the solution to this. Feel free to let me know if something doesn't make sense. Commented Jan 8, 2021 at 5:20
  • Thanks again didn't even notice . It now shows all the errors in the code . I appreciate all your help Robert thanks for everything
    – Oldnewbee
    Commented Jan 8, 2021 at 17:08
  • No problem, glad to help. Don't forget to accept an answer so the system knows that the question is resolved and doesn't keep pushing this question to the top of the feed. :) Commented Jan 8, 2021 at 17:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .