Skip to content

Instantly share code, notes, and snippets.

View inder123's full-sized avatar

Inderjeet Singh inder123

View GitHub Profile
@inder123
inder123 / camel-banana.csv
Last active August 10, 2019 23:07
Came banana problem
Mile # bananas to transport Count of 1KM segments travelled Bananas Eaten Banana Left
0 300 0 0 300
1 300 5 5 295
2 295 5 5 290
3 290 5 5 285
4 285 5 5 280
5 280 5 5 275
6 275 5 5 270
7 270 5 5 265
8 265 5 5 260
@inder123
inder123 / gist:96ddd553810fcf28d1a0938f26317e4e
Created May 26, 2017 05:35
How to install xmr-stak-cpu on MacOS X
Here is what I did to compile https://github.com/fireice-uk/xmr-stak-cpu on MacOS X successfully:
install brew
```/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"```
install cmake
```brew install cmake```
```cmake -DMICROHTTPD_REQUIRED=OFF -DOpenSSL_REQUIRED=OFF .```
Edit ```xmr-stak-cpu/minethd.cpp```
On line 51: change ```cpu_id``` with ```static_cast<integer_t>(cpu_id)```
```make install```
@inder123
inder123 / UrlParams.java
Created January 11, 2016 21:28
UrlParams: A Builder class to construct URL parameters in Java
import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;
import java.util.ArrayList;
import java.util.List;
/**
* A class to create URL parameters in a builder-like fashion
*
* @author Inderjeet Singh
*/