/*Write a function int sumLetters(char my_string[]) that has one parameter, a string of characters. The function finds and returns the sum of ASCII values of lowercase chars ONLY. Write main to test your function. You can use scanf and %s to read your string. */ #include #define SIZE 20 //19 characters and \0 int sumLetters(char my_string[]); int main(){ char str[SIZE]; printf("enter string\n"); scanf("%s", str); printf("sum ascii of letters is %d\n",sumLetters(str)); return 0; } int sumLetters(char my_string[]){ int i=0, sum=0; while(my_string[i]!='\0'){ if(my_string[i]>='a' && my_string[i]<='z') sum+=(int)(my_string[i]); i++; } return sum; }