'Undefined symbols for architecture x86_64: "_main", referenced from: implicit entry/start for main executable

#include <unistd.h>
void    ft_print_alphabet(void)
{
    write(1, 
 "abcdefghijklmnopqrstuvwxyz", 26);
}

I tried running the above in VS Code and I got the following error:

Undefined symbols for architecture x86_64:

"_main", referenced from:

implicit entry/start for main executable

ld: symbol(s) not found for architecture x86_64

clang: error: linker command failed with exit code 1 (use -v to see invocation)



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source