I am currently trying to access an element from a 2d Vector declared as such:
data Board = FullBoard Int Int
:t FullBoard
FullBoard :: Int -> Int -> Board
(FullBoard x y)
If I am correct, the two Ints Are the size of the board, in this 2d Vector.
My issue is that I cannot seem to find a way to access the (x, y) element and changing the data that is currently stored as 0
in a nested tuple. I have tried using several things including using the lens
library, however I have had no luck with a^._2
or similar getter functions.
Any help is appreciated!