@@ -2,7 +2,11 @@
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
+<<<<<<< Updated upstream
<orderEntry type="jdk" jdkName="Python 3.8 (py38) (3)" jdkType="Python SDK" />
+=======
+ <orderEntry type="jdk" jdkName="Python 3.9" jdkType="Python SDK" />
+>>>>>>> Stashed changes
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
- <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.8 (py38) (3)" project-jdk-type="Python SDK" />
+ <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.9" project-jdk-type="Python SDK" />
</project>
@@ -1,6 +1,5 @@
from typing import List
-
class Solution:
def spiralOrder(self, matrix: List[List[int]]) -> List[int]:
m, n = len(matrix), len(matrix[0])
@@ -37,4 +36,5 @@ class Solution:
if __name__ == "__main__":
s = Solution()
a = s.spiralOrder([[1,2,3,4],[5,6,7,8],[9,10,11,12]])
+
print(a)
@@ -0,0 +1,13 @@
+class TreeNode:
+ def __init__(self, val=0, left=None, right=None):
+ self.val = val
+ self.left = left
+ self.right = right
+class Solution:
+ def inorderTraversal(self, root: Optional[TreeNode]) -> List[int]:
+ if root == None:
+ return []
+ left = self.inorderTraversal(root.left)
+ right = self.inorderTraversal(root.right)
+ return left + [root.val] + right
@@ -0,0 +1,2 @@
+ def isSameTree(self, p: Optional[TreeNode], q: Optional[TreeNode]) -> bool: