Problem 45355. Connect Four - 03
I get the different answer about test 4
can u be more specific about what answer r u getting?
that's the answer my program is giving me.
@Asif Newaz, in the test4, I get
Maybe I got it wrong, I will try again
@Asif Newaz, ok , the test is right, I got it wrong
I likely had the same confusion as Binbin: [1 1 1 1 1] counts as one winning string for Player 1 (not two), whereas [1 1 1 1 1 1 1 1 1] counts as two (not one or six).
Solution CommentsShow comments
Problem Recent Solvers5
Matrix indexing with two vectors of indices
Create a matrix X, where each column is a shifted copy of the vector v
Change the sign of even index entries of the reversed vector
More from this Author165
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!