MATLAB: How to create letters, numbers and special characters

mixing letters and numbers

Hi, I want to create a column like this:
{f (A,0) }
{f (A,1) }
{f (A,2) }
{f (A,3) }
{f (A,4) }
{f (A,5) }
{f (A,6) }
{f (A,7) }
{f (A,8) }
ect
Not sure how to tell MATLAB to do this… I guess should be easy, but I don't know how to mix together all the characters without the program gets crazy. I just need a clue.
Cheers,
Yan

Best Answer

out=arrayfun(@(x) sprintf('{f(A,%d)}',x),(0:8)','un',0)
Or
out=sprintf('{f(A,%d)}\n',(0:8)')