I'm receiving the error:
/usr/bin/ld: /tmp/readability-1786f7.o: in function main': /workspaces/109105972/readability/readability.c:19: undefined reference to
count_letters'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [: readability] Error 1
when trying to use the make readability command. I've been struggling with this for hours mostly rewriting the function code in various ways. I've also looked at similar questions regarding this and have updated my vs code with "update50" and checked function "int count_letters(string text)" for grammatical errors even going so far as copy pasting it more than once.
My code:
#include <cs50.h>
#include <stdio.h>
#include <ctype.h>
int main(void)
{
// Declare functions
int count_letters(string text);
int count_letters(string);
// Get text from user
string text = get_string("Text: ");
// implement function count_letters
int cl = count_letters(text);
printf("%i", cl);
//Function performance count_letters
int count_letters(string text);
{
int l = 0;
for (int i = 0; text[i] != '\0'; i++)
{
if (isalpha(i))
{
l++;
}
}
return l;
}
}