This file contains hidden or 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
function Person(name,city){ | |
this.name=name; | |
} | |
var sorted=[]; | |
var sortDitchedMe=[]; | |
for(var i=1;i<=11;i++){ | |
var person=new Person('name'+i); | |
if(i<11){ | |
sorted.push(person); | |
} |
This file contains hidden or 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
export class SeoMetaData{ | |
title: string; | |
description:string; | |
} |
This file contains hidden or 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
function flattenArray(arr){ | |
return arr.reduce(function(initial,item){ | |
if(typeof item=="number"){ | |
initial.push(item); | |
}else{ | |
initial=initial.concat(flattenArray(item)) | |
} | |
return initial; | |
},[]) | |
} |
This file contains hidden or 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
function sortByAge(arr){ | |
arr.sort(function(obj1,obj2){ | |
if (obj1.age>obj2.age){ | |
return -1; | |
}else{ | |
return 1; | |
}else{ | |
return 0; |
This file contains hidden or 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
const ACTIVITIES = [ | |
{name: 'side-project', time: 10, xp: 12}, | |
{name: 'algorithms', time: 3, xp: 7}, | |
{name: 'networking', time: 1, xp: 0.5}, | |
{name: 'exercise', time: 2, xp: 1.5}, | |
{name: 'systems design', time: 4, xp: 4}, | |
{name: 'making CSS codepens', time: 3, xp: 4} | |
]; |
This file contains hidden or 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
Verifying my Blockstack ID is secured with the address 18x8xDkVnKDoZtECxzBhtWDhJtApQrjCJA https://explorer.blockstack.org/address/18x8xDkVnKDoZtECxzBhtWDhJtApQrjCJA |
This file contains hidden or 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
// implementation of "for of loop" | |
function forOf(iterable,callback){ | |
var iterator = iterable[Symbol.iterator](); | |
var result=iterator.next(); | |
var index=0; | |
while(!result.done){ | |
callback(result.value,index); | |
result=iterator.next(); | |
index++; | |
} |
This file contains hidden or 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
import React,{ useReducer, useEffect, useRef } from "react"; | |
import axios from "axios"; | |
const initialState = { | |
items: [], | |
loading: false, | |
error: null, | |
filter: null, | |
pagination: { |
This file contains hidden or 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
function flatten(arr){ | |
return arr.reduce((result,item)=>{ | |
if(Array.isArray(item)){ | |
result=result.concat(flat(item)) | |
}else{ | |
result.push(item) | |
} | |
return result; | |
},[]) | |
} |
This file contains hidden or 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
//developed by @kuldeepkeshwar | |
//@version=5 | |
indicator(title='SMA/EMA/RSI Signal', overlay=true) | |
// ema | |
emaInput1=input.int(55,title="value",group="EMA 1", inline="EMA 1") | |
emaInput2=input.int(100,title="value",group="EMA 2", inline="EMA 2") | |
emaInput3=input.int(200,title="value",group="EMA 3", inline="EMA 3") | |
emaInput4=input.int(300,title="value",group="EMA 4", inline="EMA 4") |
OlderNewer