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
__author__ = 'Saurabh' | |
from PIL import Image | |
IMAGE_NAME = 'RandomText.gif' | |
inputImage = Image.open(IMAGE_NAME) | |
inputImageMatrix = inputImage.load() | |
BLACK = 0 | |
WHITE = 255 |
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
from string import ascii_lowercase | |
ITERATIONS = 3 | |
charMapping = {} | |
charControl = 0 | |
for char in ascii_lowercase: | |
charMapping[charControl] = char | |
charControl+=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
import os | |
import random | |
import collections | |
def jumbleSentences(paragraph): | |
sentences = paragraph.split('. ') | |
jumbledSentences = collections.OrderedDict() | |
jumbleCounter = 0 | |
while jumbleCounter < len(sentences): | |
position = random.randrange(0, len(sentences)) |
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
#Set-ExecutionPolicy Unrestricted | |
$fromFolderPath = $args[0][0] | |
$toFolderPath = $args[0][1] | |
$toFilename = "" | |
if ($fromFolderPath.Split("\")[-1] -eq "") | |
{ | |
$toFilename = $fromFolderPath.Split("\")[-2] | |
$fromFolderPath = $fromFolderPath.SubString(0, ($fromFolderPath.length-1)) | |
} |
NewerOlder