Skip to content

Instantly share code, notes, and snippets.

@edsoliman
edsoliman / accessing array items
Created February 16, 2019 17:30
Working with arrays drills
https://repl.it/@EGS0325/Accessing-array-items-drill
@edsoliman
edsoliman / compute the average
Created February 19, 2019 01:17
Loops and Arrays
https://repl.it/@EGS0325/average-drill
https://repl.it/@EGS0325/Deleting-keys-drill
@edsoliman
edsoliman / deleting keys
Created February 20, 2019 02:03
Object Basics Drills
https://repl.it/@EGS0325/Deleting-keys-drill
@edsoliman
edsoliman / index.html
Last active March 24, 2019 23:14
quiz-app
<!DOCTYPE html>
<html lang="en">
<head>
<title>Health & Fitness Quiz</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-height intial-scale=1.0">
<link rel="stylesheet" type="text/css" href="main.css">
<link href="https://fonts.googleapis.com/css?family=Roboto+Condensed" rel="stylesheet">
</head>
@edsoliman
edsoliman / bio.txt
Created March 25, 2019 23:41
Ed's portfolio site
As a full stack developer and *graduate of the Thinkful bootcamp*, I enjoy the opportunity development gives me to apply my knowledge in solving real world problems with technology. Whether it's a bold new application that's destined to be the next Google or a simple website re-design, I'm here to aid you in the process. I'm well versed in HTML5, CSS, JavaScript/jQuery...
Outside of the Thikful curriculum, I've been working on developing a fitness application with my roommate who's also a developer. As you may have guessed, I'm a big health & fitness enthusiast. When I'm not coding, you can probably find me at Gold's Gym Venice trying to become the next Arnold Schwarzenegger. I also enjoy reading, connecting with others and spreading positivity.
Please feel free to contact me with business inquiries or opportunities via any of the below links:
*e-mail, LI, GitHub, etc.*
@edsoliman
edsoliman / question1.txt
Created April 3, 2019 00:24
How web apps work
a client/server relationship is comparable to a relationship between a child and his mother. For example, a child (client) may ask his mother (server) for a grilled cheese sandwhich. His mother then makes the sandwhich with the appropriate ingredients. She then gives the the sandwhich. The child may notice that the sandwhich is missing butter. The child then requests butter. The mother then adds butter and returns it to the child. This repeats until the child receives all the necessary ingredients that make up his sandwhich.
@edsoliman
edsoliman / question1.txt
Created April 27, 2019 21:55
How web apps work
the relationship between clients and servers is similar to the following scenario:
suppose a child asks his mom for a ham and cheese sando. the mother receives the request, makes the sando, and gives it to the child. The child realizes there is no mayo and requests mayo. The mother receives the request, adds the mayo, and gives it back to child. This process repeats itself until the sando has all its ingredients.
{ error:
{ error: sorry, too many clients already
at Connection.parseE (/Projects/work_it_out-server/node_modules/pg/lib/connection.js:604:11)
at Connection.parseMessage (/Projects/work_it_out-server/node_modules/pg/lib/connection.js:401:19)
at Socket.<anonymous> (/Projects/work_it_out-server/node_modules/pg/lib/connection.js:121:22)
at Socket.emit (events.js:189:13)
at addChunk (_stream_readable.js:284:12)
at readableAddChunk (_stream_readable.js:265:11)
at Socket.Readable.push (_stream_readable.js:220:10)
at TCP.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)
@edsoliman
edsoliman / RemoveDupsFromArr.js
Last active February 3, 2022 17:28
Remove duplicates from array - all data types with shallow objects only.
/**
* @param {{[key: string]: number}} obj1
* @param {{[key: string]: number}} obj2
* @return {boolean} equal - Are the two objects equal?
*/
const shallowCompare = (obj1, obj2) => {
// If passing in undefined values, this means the obj did not exist in the dupsHash in removeDuplicates(), so return.
if (typeof obj1 !== 'object' || typeof obj2 !== 'object') return;
const obj1Keys = Object.keys(obj1);