Basic implementation of format.