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
def Permute(queens, row): | |
for i in range(8): | |
queens[row] = i | |
if Fine(queens, row): | |
if row == 7: | |
print(' ',queens) | |
globals()["solutions"] = globals()["solutions"] + 1 | |
else: | |
Permute(queens, row+1) | |
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
# -*- coding: utf-8 -*- | |
""" | |
Created on Sat Jun 29 20:26:05 2019 | |
@author: Poshan Pandey | |
""" | |
# Python program to display the Fibonacci sequence up to n-th term using recursive functions | |
def recur_fibo(n): |