First published at 19:42 UTC on April 28th, 2020.
Squares On A Chess Board
Have I mentioned that I love maths...? Perhaps not...
This is all coded in VB.Net - no DB at all, so it's stand-alone.
Never underestimate the power of maths - it is everywhere!!!
If you are too young, then check out what a…
MORE
Squares On A Chess Board
Have I mentioned that I love maths...? Perhaps not...
This is all coded in VB.Net - no DB at all, so it's stand-alone.
Never underestimate the power of maths - it is everywhere!!!
If you are too young, then check out what a chess board even is - it's a game that I think you'll like. Maybe start with checkers/drafts...?
It presents as an 8 x 8 grid, and the classic question is - how many squares are there on the board?
This is an update to the version that I loaded, nearly 3 years ago (https://www.bitchute.com/video/dwWOp696Hx8u/)
I have changed the way I produce this, completely.
The end result is the same, it's just that I re-visited it to see what I could improve.
I originally had a grid of buttons - it's now all in a datagridview. This is faster, and needs less lines of code.
I have reduced some 600 code lines to less than 200. Pretty neat...
If you watch the video (and I am writing this as I have developed a crazy hiss on my headphones...), all I am doing is demonstrating the different combinations that are available.
I will leave it up to you to actually do the maths on this - how many squares?
As a token gesture, if you really have look into this as a new problem, do NOT start with an 8 x 8 grid!
Why do I say that? Because you can't see the wood for the trees...
What do I mean?
Think about it - start with a single square. You have 1 square (well, duh!)
Then move to a 2 x 2 square - you have 4 single squares, but you also have 1 large (2 x 2) square.
Move to a 3 x 3. This gives you (work it through...) 9 small squares, 4 x 2 x 2 squares (work it...) and 1 large square.
Do you see a pattern...? 1 + (2x2) + (3x3) + ...
It's a repeating formula/equation.
Try to work out what the answer is - without cheating.
Good luck!
LESS