Difficult Python Question 4 — Checking If Maze Is Solvable

You are given a 2-dimensional list representing a maze:
maze = [
["S", "#", "-", "-", "-"],
["-", "#", "-", "#", "-"],
["-", "#", "-", "#", "-"],
["-", "#", "-", "#", "-"],
["-", "-", "-", "#", "-"],
["#", "-", "-", "#", "X"]
]
Some Rules:
S
represents the starting spot of the player