View gist:ffde903db2e92a9fa6d6e81dc211a77d
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
### Keybase proof | |
I hereby claim: | |
* I am swapagarwal on github. | |
* I am swapagarwal (https://keybase.io/swapagarwal) on keybase. | |
* I have a public key ASADLF0jw6l5nnofd5URmLlkcgf4sgV2EpFpALzQtvmR4wo | |
To claim this, I am signing this object: |
View bigInt_C++.cpp
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
#include <vector> | |
#include <cstdlib> | |
#include <iostream> | |
#include <iomanip> | |
#include <string> | |
using namespace std; | |
typedef long long LL; | |
// base and base_digits must be consistent | |
const int base = 1000000000; | |
const int base_digits = 9; |
View linregr.py
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 numpy import loadtxt, zeros, ones, array, linspace, logspace | |
from pylab import scatter, show, title, xlabel, ylabel, plot, contour | |
#Evaluate the linear regression | |
def compute_cost(X, y, theta): | |
''' | |
Comput cost for linear regression | |
''' | |
#Number of training samples |
View HideFacebookNewsFeed
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
// ==UserScript== | |
// @name HideFacebookNewsFeed | |
// @description Saves you time by hiding Facebook news feed. | |
// @include *://*.facebook.com/* | |
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js | |
// ==/UserScript== | |
/* | |
* Author : Swapnil Agarwal | |
*/ |