By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,364 Members | 1,278 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,364 IT Pros & Developers. It's quick & easy.

What does [...] mean?

P: n/a
I'm getting a list that I build which when printed is displaying, well,
e.g.:
d = << ['electronic', 'path', 'open', 'for', 'the', 'next', 'reader',
'.', [...], 'Do', 'not', 'remove', 'thi', '.', [...]] >>

Clearly I have a problem with the truncation of the final this, but what
does the internal [...] mean?
It's generated by doing:
print "d = <<", d, ">>"

If it matters, I'm using Python 2.3.4 on Linux.

Jul 18 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Charles Hixson wrote:
Clearly I have a problem with the truncation of the final this, but
what
does the internal [...] mean?
It's generated by doing:
print "d = <<", d, ">>"

If it matters, I'm using Python 2.3.4 on Linux.


It usually means that you have a self-referencing data structure, and so
repr is being kind enough not to recursively display it forever:
l = [1, 2]
l.append(l)
l

[1, 2, [...]]

You haven't given any indication of how d was created, so it's not
really possible to help further than that.

--
__ Erik Max Francis && ma*@alcyone.com && http://www.alcyone.com/max/
/ \ San Jose, CA, USA && 37 20 N 121 53 W && AIM erikmaxfrancis
\__/ Maybe this world is another planet's Hell.
-- Aldous Huxley
Jul 18 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.