Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@ashish2199
ashish2199 / gist:d1eff15743344fea9006b05fd44f6762
Created October 13, 2021 14:58 — forked from bradfrost/gist:59096a855281c433adc1
Why I'm Not A JavaScript Developer

Answering the Front-end developer JavaScript interview questions to the best of my ability.

  • Explain event delegation

Sometimes you need to delegate events to things.

  • Explain how this works in JavaScript

This references the object or "thing" defined elsewhere. It's like "hey, thing I defined elsewhere, I'm talkin' to you."

  • Explain how prototypal inheritance works.
@ashish2199
ashish2199 / interview.js
Created August 4, 2021 17:47 — forked from gs-ysingh/interview.js
JS Interview
1. Write poly-fill of Object.create and explain why it worked:
if(typeof Object.create != "function") {
Object.create = function(param) {
var Fun = function(){};
Fun.prototype = param;
return new Fun();
}
}
@ashish2199
ashish2199 / System Design.md
Created July 11, 2021 14:58 — forked from vasanthk/System Design.md
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
import Component from '@glimmer/component';
export default class extends Component {
}
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle'
});
@ashish2199
ashish2199 / SQL Server commands and queries.md
Last active March 12, 2024 04:50
List of Microsoft SQL Server queries and commands

To create a Table

	create table risk_clos_rank(
		id_num int IDENTITY(1,1) NOT NULL,
	    username nvarchar(100),
	    datetime_of_decision DATETIME
	);
	
	CREATE TABLE TheNameOfYourTable (
 ID INT NOT NULL IDENTITY(1,1),
To initialise a new git repository
git init
To download a repository from a website
git clone https://github.com/tutorialzine/awesome-project.git
To remove commits from github.
git log
to find out the commit you want to revert
git push origin +7f6d03:master
@ashish2199
ashish2199 / .gitignore
Created November 11, 2017 14:42 — forked from chhh/.gitignore
.gitignore file for IDEA, Eclipse, NetBeans
#
# Project specific excludes
#
tomcat
#
# Default excludes
#
All challenges. I lied a bit, these are actually in **reverse** chronological order, to make it less annoying to use on mobile devices.
Easy | Intermediate | Hard | Weekly/Bonus
-----|--------------|------|-------------
| []() | []() | []() | **-** |
| [[2016-02-22] Challenge #255 [Easy] Playing with light switches](/r/dailyprogrammer/comments/46zm8m/20160222_challenge_255_easy_playing_with_light/) | [[2016-02-24] Challenge #255 [Intermediate] Ambiguous Bases](/r/dailyprogrammer/comments/47docs/20160224_challenge_255_intermediate_ambiguous/)| [[2016-02-26] Challenge #255 [Hard] Hacking a search engine](/r/dailyprogrammer/comments/47o4b6/20160226_challenge_255_hard_hacking_a_search/) | **-** |
| [[2016-02-16] Challenge #254 [Easy] Atbash Cipher](/r/dailyprogrammer/comments/45w6ad/20160216_challenge_254_easy_atbash_cipher/)| [[2016-02-17] Challenge #254 [Intermediate] Finding Legal Reversi Moves](/r/dailyprogrammer/comments/468pvf/20160217_challenge_254_intermediate_finding_legal/)| [[2016-02-19] Challenge #25
@ashish2199
ashish2199 / challenges.txt
Created August 3, 2015 19:10
Reddit r/dailyprogrammer challenge list
All challenges. I lied a bit, these are actually in **reverse** chronological order, to make it less annoying to use on mobile devices.
Easy | Intermediate | Hard | Weekly/Bonus
-----|--------------|------|-------------
| []() | []() | []() | **-** |
| [[2015-08-03] Challenge #226 [Easy] Adding fractions](/r/dailyprogrammer/comments/3fmke1/20150803_challenge_226_easy_adding_fractions/) | []() | []() | **-** |
| [[2015-07-27] Challenge #225 [Easy/Intermediate] De-columnizing](/r/dailyprogrammer/comments/3esrkm/20150727_challenge_225_easyintermediate/) | [[2015-07-29] Challenge #225 [Intermediate] Estimating pi from images of circles](/r/dailyprogrammer/comments/3f0hzk/20150729_challenge_225_intermediate_estimating_pi/) | [[2015-07-31] Challenge #225 [Intermediate] Diagonal Maze](https://www.reddit.com/r/dailyprogrammer/comments/3f9o7k/20150731_challenge_225_intermediate_diagonal_maze/) | **-** |
| [[2015-07-20] Challenge #224 [Easy] Shuffling a List](/r/dailyprogrammer/comments/3e0hmh/20150720_challenge_224_e