Skip to content

Instantly share code, notes, and snippets.

View rakeshsukla53's full-sized avatar

Rakesh Sukla rakeshsukla53

View GitHub Profile
@rakeshsukla53
rakeshsukla53 / write_data_1.csv
Created April 4, 2016 19:40
ALL DONALD TRUMP QUOTES
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 7.
Donald Trump,Quotes
Sometimes by losing a battle you find a new way to win the war.,http://www.brainyquote.com/quotes/quotes/d/donaldtrum383171.html
I have a great relationship with the Mexican people.,http://www.brainyquote.com/quotes/quotes/d/donaldtrum717755.html
"You have to think anyway, so why not think big?",http://www.brainyquote.com/quotes/quotes/d/donaldtrum153798.html
"You know the funny thing, I don't get along with rich people. I get along with the middle class and the poor people better than I get along with the rich people.",http://www.brainyquote.com/quotes/quotes/d/donaldtrum414743.html
"Our politicians are stupid. And the Mexican government is much smarter, much sharper, much more cunning. And they send the bad ones over because they don't want to pay for them. They don't want to take care of them. Why should they when the stupid leaders of the United States will do it for them?",http://www.brainyquote.com/quotes/quotes/d/donaldtrum714310.html
"That's one of the nice things. I mean, part of
@rakeshsukla53
rakeshsukla53 / write_data_1.csv
Created April 4, 2016 19:26
donald trump quotes
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 7.
Donald Trump,Quotes
Sometimes by losing a battle you find a new way to win the war.,http://www.brainyquote.com/quotes/quotes/d/donaldtrum383171.html
I have a great relationship with the Mexican people.,http://www.brainyquote.com/quotes/quotes/d/donaldtrum717755.html
"You have to think anyway, so why not think big?",http://www.brainyquote.com/quotes/quotes/d/donaldtrum153798.html
"You know the funny thing, I don't get along with rich people. I get along with the middle class and the poor people better than I get along with the rich people.",http://www.brainyquote.com/quotes/quotes/d/donaldtrum414743.html
"Our politicians are stupid. And the Mexican government is much smarter, much sharper, much more cunning. And they send the bad ones over because they don't want to pay for them. They don't want to take care of them. Why should they when the stupid leaders of the United States will do it for them?",http://www.brainyquote.com/quotes/quotes/d/donaldtrum714310.html
"That's one of the nice things. I mean, part of
Title,Title_URL
Introducing React Storybook,https://voice.kadira.io/introducing-react-storybook-ec27f28de1e2
How to Build Your Own Rogue GSM BTS for Fun and Profit,https://www.evilsocket.net/2016/03/31/how-to-build-your-own-rogue-gsm-bts-for-fun-and-profit/
Dwarf Fortress' creator on how he's 42% towards simulating existence,http://www.pcgamer.com/dwarf-fortress-creator-on-how-hes-42-towards-simulating-existence/#page-1
"Managed by Q, an On-Demand Start-Up, Raises $25M",http://www.nytimes.com/2016/04/04/technology/managed-by-q-anon-demand-start-up-raises-25-million.html?_r=0
Why a New Generation of On-Demand Businesses Rejected the Uber Model,http://www.fastcompany.com/3058299/why-a-new-generation-of-on-demand-businesses-rejected-the-uber-model
Head of Oracle Linux Moves to Microsoft,http://www.zdnet.com/article/head-of-oracle-linux-moves-to-microsoft/
Robin,http://www.redditblog.com/2016/04/robin.html
Will minimum wage hikes lead to a huge boost in automation? Only if we're lucky,http://www.vox.com/2016/4/2/
@rakeshsukla53
rakeshsukla53 / write_data_1.csv
Created April 3, 2016 03:54
hacker news data
Title Title_URL
Introducing React Storybook https://voice.kadira.io/introducing-react-storybook-ec27f28de1e2
How to Build Your Own Rogue GSM BTS for Fun and Profit https://www.evilsocket.net/2016/03/31/how-to-build-your-own-rogue-gsm-bts-for-fun-and-profit/
Dwarf Fortress' creator on how he's 42% towards simulating existence http://www.pcgamer.com/dwarf-fortress-creator-on-how-hes-42-towards-simulating-existence/#page-1
Managed by Q, an On-Demand Start-Up, Raises $25M http://www.nytimes.com/2016/04/04/technology/managed-by-q-anon-demand-start-up-raises-25-million.html?_r=0
Why a New Generation of On-Demand Businesses Rejected the Uber Model http://www.fastcompany.com/3058299/why-a-new-generation-of-on-demand-businesses-rejected-the-uber-model
Head of Oracle Linux Moves to Microsoft http://www.zdnet.com/article/head-of-oracle-linux-moves-to-microsoft/
Robin http://www.redditblog.com/2016/04/robin.html
Will minimum wage hikes lead to a huge boost in automation? Only if we're lucky http://www.vox.com/2016/4/2/
@rakeshsukla53
rakeshsukla53 / download_videos_godjango.py
Created April 3, 2016 00:34
Download Go Django Videos
from selenium import webdriver
from go_django import GoDjango
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.common.by import By
from time import sleep
def download_videos():
driver = webdriver.Firefox()
@rakeshsukla53
rakeshsukla53 / selenium-installation-guide.md
Last active April 4, 2016 18:21
Selenium Installation Guide

Python, Selenium Installation Guide Download

Installing Python and Selenium

Installing Python:

Windows : http://python.org/download/.

Note : IF you are using Linux, MacOS X, Unix operating Systems then python will be installed by default with OS

from django.http import HttpResponseRedirect
from django.conf import settings
from re import compile
EXEMPT_URLS = [compile(settings.LOGIN_URL.lstrip('/'))]
if hasattr(settings, 'LOGIN_EXEMPT_URLS'):
EXEMPT_URLS += [compile(expr) for expr in settings.LOGIN_EXEMPT_URLS]
class LoginRequiredMiddleware:
"""
@rakeshsukla53
rakeshsukla53 / zsh.md
Created December 29, 2015 14:40 — forked from tsabat/zsh.md
Getting oh-my-zsh to work in Ubuntu
@rakeshsukla53
rakeshsukla53 / tree.md
Created December 28, 2015 21:07 — forked from hrldcpr/tree.md
one-line tree in python

One-line Tree in Python

Using Python's built-in defaultdict we can easily define a tree data structure:

def tree(): return defaultdict(tree)

That's it!

@rakeshsukla53
rakeshsukla53 / BinarySearchTree
Created November 28, 2015 20:45
BinarySearchTree
http://www.pythontutor.com/visualize.html#code=class+BinarySearchTree%3A+++%23+now+you+can+perform+any+type+of+opertion+on+this+tree%0A+%0A++++def+__init__(self,+value%29%3A%0A+%0A++++++++self.value+%3D+value%0A++++++++self.right+%3D+None%0A++++++++self.left+%3D++None%0A+%0A++++def+insert(self,+data%29%3A++%23+this+will+take+the+value+and+insert+accordingly%0A+%0A++++++++if+data+%3E+self.value%3A%0A++++++++++++if+self.right+%3D%3D+None%3A%0A++++++++++++++++self.right+%3D+BinarySearchTree(data%29%0A++++++++++++else%3A%0A++++++++++++++++self.right.insert(data%29%0A+%0A++++++++elif+data+%3C+self.value%3A%0A++++++++++++if+self.left+%3D%3D+None%3A%0A++++++++++++++++self.left+%3D+BinarySearchTree(data%29%0A++++++++++++else%3A%0A++++++++++++++++self.left.insert(data%29%0A++++++++else%3A%0A++++++++++++self.data+%3D+data%0A++++++++++++%0Aroot+%3D+BinarySearchTree(1%29%0Aroot.insert(2%29&mode=display&origin=opt-frontend.js&cumulative=false&heapPrimitives=false&textReferences=false&py=2&rawInputLstJSON=%5B%5D&curInstr=1