Skip to content

Instantly share code, notes, and snippets.


Jeevan M R jee1mr

View GitHub Profile
jee1mr /
Created Mar 16, 2020
Python program for generating all possible combinations of small/upper case letters of a word
import sys
word = sys.argv[1]
n = len(word)
num_of_combs = 2**n
for i in range(num_of_combs):
num = bin(i)[2:].zfill(n) # if cat 000, 001, 010.. if jack 0000, 0001, 0010...
print(''.join([ word[index].upper() if value == '1' else word[index].lower() for index, value in enumerate(num)]))
jee1mr / cowswamy_debates.txt
Created Apr 11, 2019
List of Prime Time Debate Titles of Republic TV featuring Arnab Goswami since May 2017
View cowswamy_debates.txt
Bollywood takes sides this election, it's 616 artistes VS 907 artistes
Was Madhya Pradesh govt scheme funds diverted via Hawala?
Were funds stolen from schemes which were meant for malnourished children and pregnant mothers in Madhya Pradesh?
5 killed in a Maoist attack in Dantewada, Chhattisgarh.Why are the #UrbanNaxalsSilent?
RSS leader gunned down in Kishtwar, why are Kashmir terror apologists silent?
With the focus on the last mile, has the BJP hit home with it's vision document?
Is appeasement over development in elections 2019?
Unbelievable cash stash. Whose money was it anyway?
Was a family bribed?
Rahul Gandhi wants to muzzle media?
jee1mr / gogetauto
Created Jul 6, 2015
Auto script for getting Go dependencies
View gogetauto
import re
import commands
build_error = commands.getoutput("go build")
print "go build errors:"
print build_error
sources = re.findall(r"cannot find package \"[a-zA-Z.\/]*\"",build_error)
jee1mr /
Last active Aug 29, 2015
ISE-6th Sem ST_Lab_Program_1
import sys
x,y,z = map(int,raw_input().split())
except ValueError:
print "Invalid Input"
if not (x<y+z and y<x+z and z<x+y):
print "Triangle cannot be formed"
jee1mr / quora_sneak.js
Created Nov 26, 2014
Paste this on your browser developer console and hit enter. You can continue reading quora answers without any hassle
View quora_sneak.js
var divs = document.getElementsByTagName("div");
var x = []
for(var i=0;i<divs.length;i++){
jee1mr /
Last active Aug 29, 2015
Puts all the images in a folder to the html file and opens it in a web browser
from glob import glob
import webbrowser
images = glob("*.jpg") + glob("*.png")
f = open("comic.html","w")
imgbegin = "<img src='"
imgend = "'>"
for src in images:
You can’t perform that action at this time.