Python Forum
How many times does it fit? help please
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How many times does it fit? help please
#1
What im trying to do is to check how many times does an 1x1 slice fits in the entire array, i used slice to get array "fragments" but how to check how many times that fragment fits inside the entire array?
the 1x1 fits 64 times, 2x2 16.....
Tablero means board, by uxu i mean 1x1, dxd = 2x2....
import numpy as np

tablero = np.zeros((8,8))
print(tablero)

uxu = tablero[0:1,0:1]
print(uxu)

dxd = tablero [0:2,0:2]
print (dxd)

txt = tablero [0:3,0:3]
print (txt)
Reply


Messages In This Thread
How many times does it fit? help please - by skriff - Sep-11-2017, 01:06 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Find how many times a user played an artist and how many times disruptfwd8 1 2,674 May-04-2018, 08:32 AM
Last Post: killerrex

Forum Jump:

User Panel Messages

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