••• Unprocessable paragraph: \start
Home Segments Index Top Previous Next

560: Practice

\slidefont

••• Unprocessable paragraph: In \express/, \code{Transcript} is a global variable bound to an instance of a class. Implement \code{<<}, a binary method that prints its argument in the text window provided as the receiver. Using \code{<<}, you can write display expressions that resemble those used in \cpp/, such as the following: \par C:\Phw\Onto\Smalltalk\overload.tex •••

Workspace
Transcript << 2 << ' + ' << 2 << ' = ' << (2 + 2) 
Transcript 
2 + 2 = 4 

C:\Phw\Onto\Smalltalk\overload.tex •••