-1

It was working perfectly for others c file but in this file it fail to run . Please do explain , as i am new to Programming world.

C:\Desktop\C Basic\recursiveFunction> gcc .\pratice.c

PS C:\Desktop\C Basic\recursiveFunction> gcc .\a.exe

.\a.exe: file not recognized: File truncated collect2.exe: error: ld returned 1 exit status

  • Please take the [tour] and read [ask]. Also, check out the description of the tags that you applied. You can [edit] your question to fix these issues. – Ulrich Eckhardt Apr 26 '20 at 08:21
  • @MemReflect . Thank you so much. file successfully compiled. – Suraj Gaire Apr 26 '20 at 08:31
  • 3
    Close voters, please understand that what would be a typo for an experienced programmer is an example of a lack of understanding in a beginner and hence an on-topic question. – Yunnosch Apr 26 '20 at 08:31

1 Answers1

1

gcc is the compiler. You compile your program using gcc .\pratice.c. You can remove the .\ since gcc will look in the current directory for source files anyway.

You execute your compiled program using .\a.exe.

MemReflect
  • 551
  • 2
  • 10