Question: My prof instructed as to write an apology string using functions but I don't know how does it works and how I will define the sendApology function so here's my code:

```
    #include<stdio.h>

void sendApology(char, int);

int main(void) {
    sendApology('s', 2);
    sendApology('f', 10);
    sendApology('b', 3);
    sendApology('o', 5);
    sendApology('r', 12);
    sendApology('m', 5);
    sendApology('v', 2);
    sendApology('y', 7);

    return 0;
}

void sendApology(char letter, int n) {

  // TODO: Implement the function definition

}

```

The instruction says: "The sendApology() function will first check if the character passed is either 's', 'o', 'r', or 'y'. If it is, print it based on the passed integer number of times. For example, if the passed integer is 5, then you need to print the character 5 times. Otherwise, just ignore it (i.e. don't do anything)." but I couldn't comprehend it well, appreciate for your help thaankss

Answer: 
In simple terms, the instruction is saying:

1. Check if the variable `letter` is 's', 'o', 'r', or 'y'.
2. If it is one of these characters, print `letter` `n` times where n is the argument `n`
3. If it is not, do nothing

Some scenarios:

```
    sendApology('s', 2); // "ss"
    sendApology('f', 10); // nothing
    sendApology('b', 3); // nothing
    sendApology('o', 5); // "ooooo"
    sendApology('r', 12); // "rrrrrrrrrrrr"
    sendApology('m', 5); // nothing
    sendApology('v', 2); // nothing
    sendApology('y', 7); // "yyyyyyy"

```
The functions you need is just putc()
Put it in a loop on the count, and test if your character matches before using a loop on the range of accepted character.