Question: Yesterday I learned of this really cool way to use function pointers.
Although I think its a really cool thing to be able to do I cant see WHY and WHERE this sort of method will be used?

Could someone shed some light on this?

```
int Mul(int x , int y)
{
return x*y;
}

int Div(int x , int y)
{ return x/y;
}

typedef int (*FuncP)(int,int);

int compu(FuncP functionP, int x , int y)
{return functionP(x , y)}

```

//Calling it will look like

```
compu(Mul,5,10);

```

Thanks
Cart

Answer: 
you can use cut also 

syntax like, 

```
while read line 
do

echo $line | cut -f <required fields> -d "," >> newfile.csv

done < inputfile

```

syntax is not perfect but will do.
Like this with `awk`:

```
awk -F, '{printf "%s,%s,%s,%s\n",$6,$7,$8,$9}' file > newfile.csv

```

That `-F,` sets the field separator to a comma and it then extracts the 6th through 9th field on each line.