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

What does [::-1] means in Python?

P: 1
what does [::-1] means in python?
Jul 29 '12 #1
Share this Question
Share on Google+
2 Replies

Expert Mod 2.5K+
P: 2,851
That represents an extended slice. The "-1" represents the stride.

Extended slices
Jul 29 '12 #2

Expert Mod 2.5K+
P: 3,503
For your reference, @jorinos.
Jul 31 '12 #3

Post your reply

Sign in to post your reply or Sign up for a free account.