You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: printf.go
    path of file: ./repos/gleam/util
    
    the code of the file until where you have to start completion: package util

import (
	"fmt"
	"io"

	"github.com/chrislusf/gleam/pb"
)

// TsvPrintf reads TSV lines from reader,
// and formats according to a format specifier and writes to writer.
func TsvPr
    
func PrintDelimited(stat *pb.InstructionStat, reader io.Reader, writer io.Writer, delimiter string, lineSperator string) error {
	return ProcessMessage(reader, func(encodedBytes []byte) error {
		var row *Row
		var err error
		// fmt.Printf("chan input encoded: %s\n", string(encodedBytes))
		if row, err = DecodeRow(encodedBytes); err != nil {
			return fmt.Errorf("Failed to decode byte: %v", err)
		}
		stat.InputCounter++

		var written = 0

		// fmt.Printf("> len=%d row:%s\n", len(decodedObjects), decodedObjects[0])
		if written, err = fprintRow(writer, 0, delimiter, row.K...); err != nil {
			return fmt.Errorf("Failed to write row: %v", err)
		}
		if _, err := fprintRow(writer, written, delimiter, row.V...); err != nil {
			return fmt.Errorf("Failed to write row: %v", err)
		}

		if _, err := writer.Write([]byte("\n")); err != nil {
			return fmt.Errorf("Failed to write line separator: %v", err)
		}
		stat.OutputCounter++
		return nil
	})
}