Python Forum
movement in a zigzag in a 2d array
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
movement in a zigzag in a 2d array
#2
dir = 1
for row in list_of_rows:
    for column in row[::dir]:
        ....
    dir *= -1
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
Reply


Messages In This Thread
movement in a zigzag in a 2d array - by ShakeDat53 - Aug-17-2018, 04:56 PM
RE: movement in a zigzag in a 2d array - by ichabod801 - Aug-17-2018, 08:22 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  how to make the movement humanized isv 4 1,575 Jul-29-2022, 07:14 PM
Last Post: XavierPlatinum
  How to get continuous movement whilst using State Machine cjoe1993 2 1,829 Dec-10-2020, 06:36 AM
Last Post: cjoe1993
  An important question is how to create a zigzag in price data? epsilon 0 1,315 Nov-18-2020, 08:06 PM
Last Post: epsilon
  zigzag example shabux 10 5,432 Jul-11-2020, 11:15 PM
Last Post: bowlofred
  Moving mouse so that games can detect movement SheeppOSU 2 1,963 Jun-09-2020, 07:23 PM
Last Post: SheeppOSU
  need help on solving and movement Tankey2630 1 1,688 Jan-09-2020, 11:04 AM
Last Post: Tankey2630
  Count to movement according to the time pressed button noartist 1 2,524 Feb-27-2019, 01:33 PM
Last Post: noartist
  Can't change Right to left id spawning/ movement to top to bottom Kingrocket10 3 3,833 Dec-14-2017, 11:05 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020