#include <stdio.h>
#include <string.h>

int sum_str(char buff[]) {
  int sum = 0;
  for(int i = 0;i<strlen(buff);i++) {
    sum += buff[i];
  }
  return (sum);
}

int main() {
  char buff[] = "A String to operate on";
  int sum = 0;

  sum = sum_str(buff);
  printf("Sum of string %s ascii values is %d\n",buff,sum);
  return (0);
}
