Skip to content

Instantly share code, notes, and snippets.

View xxbinxx's full-sized avatar
🎯
Focusing

Bineet Kumar Gaur - Pythonist (---===e Max) xxbinxx

🎯
Focusing
  • http://bineetkumar.com
  • India
View GitHub Profile
@xxbinxx
xxbinxx / random_3_number_array_sum_equal_key.py
Created May 9, 2020 18:33
Python program to return True if sum of any 3 numbers in array is equal to key else return false
# -*- coding: utf-8 -*-
"""
Created on Sat May 9 23:28:42 2020
@author: bineet
"""
# given an array and if sum of any 3 numbers in array is equal to key
# then return true else false
@xxbinxx
xxbinxx / Stack in python
Last active May 23, 2019 09:45
linkedlists, stack (LIFO) implementation in python + Test cases
"""
LinkedLists, Stack implementation using python classes and methods
Added methods to our LinkedList class,
and use that to implement a Stack.
we have 4 functions below: insert_first, delete_first, push, and pop.
Think about the underlying working before checking out the code"""
class Element(object):
def __init__(self, value):
@xxbinxx
xxbinxx / LinkList in python
Created May 23, 2019 08:03
linklist implemented using python + Test cases
@xxbinxx
xxbinxx / 2 page view in google doc
Last active September 8, 2022 15:59
view 2 pages at once in google docs.
// Use this JS in your google doc browser console
// Courtesy https://coderwall.com/p/qvdxia/2-page-view-in-google-docs
(function(d, t, z, s) {
s = d.createElement(t);
s.innerHTML = z + '-outer{left:0px !important;}' + z + '-outer,' + z + '-inner{width:100% !important;}.kix-page{float:left; width:48% !important;}';
d.getElementsByTagName(t)[0].parentNode.appendChild(s);
})(document, 'style', '.kix-zoomdocumentplugin');
import requests
from bs4 import BeautifulSoup
link = "https://www.sslproxies.org/"
response = requests.get(link)
soup = BeautifulSoup(response.text,"lxml")
https_proxies = filter(lambda item: "yes" in item.text,
soup.select("table.table tr"))
for item in https_proxies:
print("{}:{}".format(item.select_one("td").text,
@xxbinxx
xxbinxx / knockout-multi-image-upload.html
Last active June 15, 2018 05:47
knockout multiple image upload snippet (bootstrap 4) // source http://jsbin.com/sojaxos
<html>
<head>
<title>knockout multiple image upload snippet</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet" integrity="sha384-wvfXpqpZZVQGK6TAh5PVlGOfQNHSoD2xbE+QkPxCAFlNEevoEH3Sl0sibVcOQVnN" crossorigin="anonymous">
</head>
<body>
<div id="page-profile-update">
@xxbinxx
xxbinxx / pydrive_usage_sample.py
Last active March 28, 2017 11:20
Example usage for python wrapper 'pyDrive', can also be used with django.
#!/usr/bin/python
#-------------------------------------------------------------------------------
# DOCS : https://googledrive.github.io/PyDrive/docs/build/html/index.html
# GITHUB REPO : https://github.com/googledrive/PyDrive
# example usage for python wrapper 'pyDrive'
# This example will create a file named "Hello.txt" with content 'Hello World!'
# in the drive of authenticated user.
#-------------------------------------------------------------------------------
@xxbinxx
xxbinxx / materialize_circular_button_with_icon
Last active July 11, 2016 10:30
circular button with materialize with a icon inside.
<!DOCTYPE html>
<!-- circular button with materialize by github.com/xxbinxx web:bineetkumar.com check output here: http://jsbin.com/gihone -->
<html>
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.97.1/css/materialize.min.css">
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
</head>