Skip to content

Instantly share code, notes, and snippets.

@newbazz
newbazz / TextEditor.py
Created June 2, 2018 11:34
This is a python text editor written in python 2.
from Tkinter import *
from tkFileDialog import *
'''
In this I have tried to make a text editor using
python's Tkinter module.
'''
filename = None
def new_file():
'''
@newbazz
newbazz / beautifulsoup.py
Created June 1, 2018 20:05
After running `python2 beautifulsoup.py`, run `firefox output.html` to see the results.
from bs4 import BeautifulSoup
import re
import urllib2
import urllib
'''
This is a small script written in order to
understand how beautiful soup works in python
and also what are all the functionalities it provides.
@newbazz
newbazz / move.sh
Created December 7, 2017 04:19
Move multiple files to multple destination
echo "Give the name of the files you want to move with their relative paths (comma separated)"
read inp
echo "Give the destinations of the files to be moved (comma separated)"
read des
files=$(echo $inp | tr "," "\n")
destination=$(echo $des | tr "," "\n")
for i in $files
do
for j in $destination
do
@newbazz
newbazz / copy.sh
Created November 30, 2017 05:02
Helps in copying various files to various destinations
echo "Give the name of the files you want to copy with their relative paths (comma separated)"
read inp
echo "Give the destinations of the files to be copied (comma separated)"
read des
files=$(echo $inp | tr "," "\n")
destination=$(echo $des | tr "," "\n")
for i in $files
do
for j in $destination
do
game/bomb.py
[ 137] ········if·self.x·>·1·and·(perm[self.y][self.x-1]·==·2·or·perm[self.y][self.x-1]·==·0):
**** PycodestyleBear (E501) [Section: autopep8 | Severity: NORMAL] ****
! ! E501 line too long (87 > 80 characters)
[ ] *0. Do (N)othing
[ ] 1. (O)pen file
[ ] 2. Add (I)gnore comment
[ ] Enter number (Ctrl-D to exit): 0
game/bomb.py