Ask your own question, for FREE!
Computer Science 20 Online
OpenStudy (curry):

help with c code, it doesn't run. it says ld returned 1 exit status. How do i compile this?

OpenStudy (curry):

i have a header file with void printChange(int change); too. so i can't see what's the problem

OpenStudy (anonymous):

You need a main function.

OpenStudy (curry):

wait it says to replace the main function though.

OpenStudy (anonymous):

But without a main function, the program will not work

OpenStudy (anonymous):

You can have the main function call the other function. That will make it run

OpenStudy (curry):

so here is my main_change class.

OpenStudy (curry):

now i compiled main_change, but it says undefined reference to printchange

OpenStudy (curry):

wait it works now, thanks!

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!