Skip to content

Instantly share code, notes, and snippets.

View mjarpitanand's full-sized avatar
:octocat:
Focusing

arpit anand mjarpitanand

:octocat:
Focusing
  • Rely
  • Banglore
View GitHub Profile
var Rely = {};
/* New variables */
var image_width = '87px';
if(product_type === "rely"){
image_width = '50px';
}
// paylater , installement, rely
let arr = [2,45,67,89,100,103];
let key = 80;
function binary_serch(arr , key){
let low = 0;
let high = arr.length - 1;
while(low <= high){
let mid = Math.floor((low+high)/2);
console.log(low, mid, high)
if(arr[mid] > key){
high = mid - 1;
#Heroku view all apps
->heroku apps
#Heroku delete one app
->heroku apps:destroy --app APP
#Heroku create app
->heroku create app-name
#Heroku keys add
function LinkedList(){
let head = null;
let node = function(ele){
this.ele = ele;
this.next = null;
}
this.insertFirst = function(ele){
let n = new node(ele);
if(head === null){
function Queue(){
var items = [];
this.enque = function(ele){
items.push(ele);
}
this.deque = function(){
return items.shift();
}
this.print = function(){
function priorityQueue(){
var items = []; //main array for the queue
function queueElement(item , pos){
this.item = item;
this.pos = pos;
}
var added = false;
this.enque = function(item , pos){
var q = new queueElement(item , pos);
function Queue(){
var items = [];
var p = "";
this.enqueue = function(element){
items.push(element);
}
this.dequeue = function(){
items.shift();
}
this.front = function(){
function dec2anybase(num , base){
var arr = [] , rem =0 , count = "";
var n = num , b = base;
while( n > 0){
rem = Math.floor(n % b);
arr.push(rem);
n = Math.floor(n /b);
}
//alert(arr);
function dec2bin(num){
var arr = [] , rem =0 , count = "";
var n = num;
while( n > 0){
rem = Math.floor(n % 2);
arr.push(rem);
n = Math.floor(n /2);
}
//alert(arr);
@mjarpitanand
mjarpitanand / stego.py
Created November 15, 2017 12:14 — forked from SharadKumar97/stego.py
This script will hide any text behind any file.
# This script hide's text behind any media file like jpg file, mp3 file ecetera.
# This script accepts two parameter for hiding text and one parameter for finding text.
# Please install steganography python library by - pip install steganography
# This script is compatible with python 2.7
from __future__ import absolute_import,unicode_literals
import argparse
from steganography.steganography import Steganography
parser=argparse.ArgumentParser()
parser.add_argument("--carrier",help="Give path of carrier file which will contain our text.")