Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /bin/python | |
class BinTree(): | |
def __init__(self, root=''): | |
self.left = None | |
self.right = None | |
self.root = root | |
def LeftChild(self): | |
return self.left |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /bin/python | |
class BinTree(): | |
def __init__(self, root=''): | |
self.left = None | |
self.right = None | |
self.root = root | |
def LeftChild(self): | |
return self.left |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Uses python3 | |
import sys | |
def largest_number(a): | |
#write your code here | |
def numCmp(a,b): | |
''' | |
:param a: | |
:param b: a and b - strings of int |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Uses python3 | |
import sys | |
import itertools | |
from random import randrange | |
def largest_number(a): | |
#write your code here | |
def numCmp(a,b): | |
''' |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# uses Python3 | |
# The n-queens puzzle is the problem of placing n queens on an n×n chessboard such that no two queens attack each other. | |
# | |
# | |
# | |
# Given an integer n, return all distinct solutions to the n-queens puzzle. | |
# | |
# Each solution contains a distinct board configuration of the n-queens' placement, where 'Q' and '.' | |
# both indicate a queen and an empty space respectively. | |
# |
OlderNewer