def format_as_index(indices):
if not indices:<EOL><INDENT>return "<STR_LIT>"<EOL><DEDENT>return "<STR_LIT>" % "<STR_LIT>".join(repr(index) for index in indices)<EOL>
Construct a single string containing indexing operations for the indices.

For example, [1, 2, "foo"] -> [1][2]["foo"]

Arguments:

    indices (sequence):

        The indices to format.