This is documentation for Mathematica 6, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)

StringForm

StringForm["controlstring", expr1, ...]
prints as the text of the controlstring, with the printed forms of the expri embedded.
  • `i` in the control string indicates a point at which to print expri.
  • `` includes the next expri not yet printed.
  • `.` prints a raw ` in the output string.  »
  • StringForm acts as a "wrapper", which affects printing, but not evaluation.
  • You can use StringForm to set up "formatted output".
  • Messages given as values for objects of the form s::t are used as control strings for StringForm.
Insert a single value into a string:
In[1]:=
Click for copyable input
Out[1]=
 
Insert a sequence of values into a string:
In[1]:=
Click for copyable input
Out[1]=
 
Insert indexed values:
In[1]:=
Click for copyable input
Out[1]=
New in 1 | Last modified in 5