fabiochiu/medium-articles huggingface dataset:
A Toilet on Steroids
By: Tracy Stengel
Tags: Humor, Health, Consumerism, Life, Nonfiction

Sam, my husband, comes in from taking the dog out. He says, “I just helped Joe unload a toilet and bring it in the house.”

Joe and Kathy live next door.

“That was nice of you!” I say, not shifting my gaze from my computer.

“Yeah, he says it’s guaranteed not to clog. They tested it with 25 pounds of dog food.”

That gets my attention. My head snaps up and swivels towards him. “Wait … what?”

Sam laughs. “I know, it’s crazy! Twenty-five pounds of dog food is a lot.”

I make a face. I know Joe and Kathy have had recent health issues, but this seems extreme. “Are they alright?”

I talk to them regularly. Have their conditions changed?

Sam shrugs as he heads to the kitchen to give our dog a treat. “I think so. Joe didn’t say anything.”

I hear him chuckle when he realizes why I’m asking.

I sit there in awe. Holy shit! Twenty-five pounds of dog food!

Comparisons race through my head like a slideshow on crack.

“Uh, who exactly tested it?”

Sam says, “I don’t know. I guess the salesman mentioned it. It was an American Standard.”

My fingers fly across the keyboard. I couldn’t find any evidence of American Standard doing tests with dog food. However, their website boasts you can flush a bucket of golf balls, no problem.

Say what? Who are these monsters?

That particular toilet is named the Champion 4. I snicker at the name. Surfing through several websites, I run across these descriptions for “The Champ”: swallows like a tornado, brute force, flushes away mass that is 70% larger compared to other toilets.

Wow!

I do a few calculations. A standard golf ball bucket holds 40 golf balls and the average golf ball weighs 1.620 ounces. So, a bucket full of balls weighs a little over 4 pounds. Nowhere near 25 pounds, but still impressive.

I’m not sure if the salesman is a braggart or if American Standard’s website is being modest. Maybe they’re nervous customers may try to “push the limit” so to speak.

What does 25 pounds of dog food look like? I have no idea! Our dog, Pippa, (middle name Potamus) is 5 pounds. Her dog food comes in a 3.5 pound bag. If someone drops 25 pounds in a toilet, it would be like excreting 5 Pippas.

That’s not even possible! Is it?

I’m not minimizing the 40 golf balls. Anyone capable of replicating something like that is no slouch. It’s only a few ounces shy of a Pippa.

I need to stop using Pippa as a unit of measurement.

Pippa Potamus 💕 Photo curtesy of author

Months ago, I decide I’m not doing any more bathroom humor. I tell myself I am not that juvenile, that I am way beyond that.

Yeah, well, I guess I’m not.
[백준] C 알고리즘 풀이ㅡ1075번
Tags: Algorithms, Baekjoon, C

in Both Sides of the Table
Parable of the Sower: I Control the Soil
By: Emma Copper
Tags: Christian Living, Bible, Jesus, Gospel, Christianity

When I was growing up, I didn’t understand the parable of the sower.

It didn’t make sense to me.

If you’re a Christian, you’re probably familiar with it. Jesus tells it this way in Matthew 13:3–9:

“A farmer went out to sow his seed. As he was scattering the seed, some fell along the path, and the birds came and ate it up. Some fell on rocky places, where it did not have much soil. It sprang up quickly, because the soil was shallow. But when the sun came up, the plants were scorched, and they withered because they had no root. Other seed fell among thorns, which grew up and choked the plants. Still other seed fell on good soil, where it produced a crop — a hundred, sixty or thirty times what was sown. Whoever has ears, let them hear.”

Classic Sunday school fare, yes? Complete with a coloring book page?

Jesus then explains the meaning of the parable in Matthew 13:18–23:

“Listen then to what the parable of the sower means: When anyone hears the message about the kingdom and does not understand it, the evil one comes and snatches away what was sown in their heart. This is the seed sown along the path. The seed falling on rocky ground refers to someone who hears the word and at once receives it with joy. But since they have no root, they last only a short time. When trouble or persecution comes because of the word, they quickly fall away. The seed falling among the thorns refers to someone who hears the word, but the worries of this life and the deceitfulness of wealth choke the word, making it unfruitful. But the seed falling on good soil refers to someone who hears the word and understands it. This is the one who produces a crop, yielding a hundred, sixty or thirty times what was sown.”

As a kid, this parable didn’t make sense to me. Oh, don’t get me wrong, I understood the story.

I just didn’t understand the point.

Why did Jesus tell it? To share general knowledge?

“Hey! Some people will hear Christianity’s message, and it will work. Others won’t hear it. It won’t work. Have a nice day.”

Was that the point of the parable? “Oh, well, that’s the way it goes…?”

It wasn’t until I hit my mid-twenties that the parable finally made sense to me.

I’d been struggling with my own faith, struggling with my inability to absorb truth and keep God’s perspective close. Suddenly the parable of the sower crashed back into me, and I had a light bulb moment.

“Ohhh…”

I control the soil.

Is that the point? Maybe not. But I think it might be.

As a kid, I took this parable to be about some people whose lives were predetermined. Rocky soil? Oh no! Weeds? Oh, well!

I also considered it to be about evangelism alone.

But lately, I’ve been considering it in more personal terms. When I walk into church on Sunday morning, I have control over the soil of my mind. And often, very deliberately, I leave those rocks there, because I’m way too lazy to do anything about them.

At the end of the day, I decide if the seed grows.
How to Conquer Your Fears in 2020
By: Mary Elisabeth
Tags: Entrepreneurship, Success, Goals, Motivation, Fear

I used to do so many more things that scared me. Before the age of 10, I jumped horses over fences.

Earlier in my career, I wrote something in the morning and published it publicly that same afternoon. Very little editing. I didn’t let the fear hold me back from horseback riding and I didn’t let the fear hold me back from publicly sharing what I had to say.

In 2015 I started a weekly practice, “Fear Burning Fridays” and every Friday for an entire year I wrote down a fear, shared the fear, and then lit that fear on fire. 52 fears.

This practice helped me as an entrepreneur.

Writing, sharing, and burning my fears helped me clean up any fears blocking me from doing something that involved a lot of uncertainty, from making a decision, from doing something that is scary, which for all you entrepreneurs out there, know there’s a lot of that!

This practice helped me as a human.

It helped me identify what was going on and impacting my relationship with myself, with others, and what buried fears, insecurities and anxieties were influencing how I went through life. That awareness was the first step in making a change and not letting the fear have power over me.

This practice helped me regain my power.

The fear doesn’t necessarily go away. It’s still there. What this practice helped me with was to identify a fear that was holding me back, feel the fear, and act anyway. One morning I burned a fear of swimming without a wetsuit in the San Francisco Bay (sometimes I was terrified to do!) and hours later I was in the water numb and feeling like I might die.

I felt the fear and did it anyway.

With IMPROV(E) we practice feeling and expressing emotion in different ways (depending on what the situation calls for, i.e. situational awareness). We practice feeling the emotion, expressing it, and then moving on. Holding on to it causes havoc in our minds and bodies. We are not defined by our feelings. Our feelings change. We allow them to change when we feel them and express them. This practice of burning fears is a practice everyone can do, wherever you are, without signing up for a class. It is a practice we use in Improve. We are saying “yes” acknowledging the feeling in the present moment, “and” expressing it “and” continuing on in the scene!

I’ve decided to re-ignite (ha!) this practice for 2020, and I invite you to do the same. Each Friday I’ll be burning a fear and sometimes will share that fear and what burning it has allowed me to breakthrough. Join me in writing, sharing, and burning your fears if you want to feel your fear and act fearlessly anyway. Please tag me when you share a fear that you’re burning so that I can support you and encourage your courage.

Say “yes, and” feel the fear and do it anyway.

Here’s to a courageous new year and a new decade!

😊
Desperately Seeking Validation
Tags: Psychology, Love And Dating, Self Improvement, Personal Growth, Relationships

You can please some of the people all of the time, you can please all of the people some of the time, but you can’t please all the people all of the time — Abraham Lincoln

People pleasing sounds like it should be a good thing; an earnest pursuit; but actually it’s a behavioural kink formed in childhood, occurring when a child becomes overly compliant in meeting their parent’s needs, in order to gain love, approval, and acceptance.

In other words, the need to please is borne out of insecurity, low self-esteem, and a desperate need to gain power, love, approval, and acceptance .

In adulthood, this learnt behaviour can manifest itself as an insidious manipulation tool, whereby we try to become all things to all people, and are reliant on controlling the opinion of others, in order to manage our own insecurities and self-love deficit.

In simple terms, people pleasing equates to saying Yes, when inside we’re screaming No; to habitually prioritising others over ourselves; to violating our personal boundaries; abandoning our moral code; bypassing our integrity, and acting disingenuously.

There’s only one reason we contort ourselves to comply with the expectations of others in this crude way; it’s because when the validation comes, the adrenal hit feels good, like a drug, and the opposite makes us feels worthless, shameful, ‘not enough’.

In a romantic context, people pleasing manifests as ‘love bombing’ — whereby somebody cycles in and out of your life like a mini tornado, showering you with gifts, acts of service, attention, compliments, and affection, only to disappear as soon as their needs have been met.

This ‘fake love’ fix can severely test your discernment, and confuse the hell out of you, as you are picked up and put you down like a toy, erroneously given false hope for something more, but never getting it.

Ultimately, this disingenuous way of living is both exhausting and toxic, leading to endless turmoil in relationships, and huge disruption to one’s well being.

The way out of this maze is simple: embrace personal integrity; be yourself, warts and all, and care less about what other people think. Remember:
Bite-Sized Fiction: Ring Gnomes
By: Quinn Cooke
Tags: Gnomes, Short Story, Bite Sized Fiction

Gnomes are hard to draw.

One morning while walking his pet mushroom hound, Gerald the Gnome happened across something he had never seen in the forest before. The object was immense (by gnome standards), rectangular, and made of a shiny, yellow material which Gerald at first mistook for metal. He approached the object while his mushroom hound whimpered and cowered next to a tree.

“Don’t worry, Sporesy,” Gerald said, “I don’t think it is dangerous.”

He tugged at the leash half-heartedly, but Sporesy refused to move. He sighed and turned his attention back to the object. He knocked on its shiny surface.

“Hmm. This isn’t metal or wood. I wonder what it could be?”

He slid his gnarled hands beneath the object and lifted, surprised at its lightness. The underside was black with a sheen like a beetle’s back, and he wondered if the object was a discarded carapace from some unknown insect.

At that moment, the object began to violently shake. The underside lit with a multi-colored light and a cacophony of drums, buzzing noises, and a deep voice shouting echoed through the forest. Sporesy bayed in dismay and fled back along the path, Gerald on his heels sprinting as fast as his gnome legs would carry him.

Over the generations the mystery of the God Box grew. Older gnomes would tell of how Gerald the Great fought the demons which came from it, and younger gnomes would dare each other to go into the woods as a test of bravery, though none ever made it all the way to the grove where the box still lies to this day, silent and brooding.

The moral of the story: Be sure to silence your phone before going into a meeting. It is rude to interrupt the speaker.
JavaScript Algorithms: FizzBuzz
By: Michael Jiang
Tags: Algorithms, JavaScript, Programming, Coding, Software Development

Fizz…Buzz…FizzBuzz? This classic and fun little technical interview question will really tackle your understanding of the modulus operator!

Photo by Crissy Jarvis

FizzBuzz is a pretty simple interview question that comes up often. It’s one of those questions that after you see the answer once, you’ll always remember how to solve it from then on out. The only tricky part about this entire problem is the usage of the modulus operator. According to the MDN Web Docs, the modulus/remainder operator (%) returns the remainder left over when one operand is divided by a second operand. It always takes the sign of the dividend. So if I write 12 % 5, it will return 2 because 5 goes into 12 twice with a remainder of 2. With that said, let’s get started:

Write a function that prints out a number from 1 to x. However, you must abide by these rules:

For every multiple of 3, print “fizz” instead of the number.

For every multiple of 5, print “buzz” instead of the number.

For every multiple of both 3 and 5, print “fizzbuzz” instead of the number.

For example, fizzBuzz(5) will return:

1

2

fizz

4

buzz

If we break up the question into smaller parts, the very first part is simply iterating from 1 to x. That can be easily accomplished using a manual for loop:

Within the for loop, we’re going to set a few conditions. Specifically, the conditions where the number being printed out is a multiple of 3, 5, or 3 and 5 (which is basically 15). These conditions will be using the modulo operator because at any point, if the number being printed out is divisible by 3, 5, or 15, then the modulo should return 0. Let’s implement those conditions:

Lastly, we want to make sure that we print out the number if none of the conditions match, which is why we have a console.log(i) at the end.

If we run through with the example of fizzBuzz(5), we start with 1 going through the conditionals. Because it does not satisfy any of the conditions, it will be printed out. The same happens for 2. Once we hit 3, because 3 modulo 3 gives us 0, the condition becomes true and we will print out fizz instead. 4 Also does not satisfy any conditions, so it will be printed out again. When we hit 5, 5 modulo 5 is equal to 0, so that condition also returns true, therefore printing out buzz.

This question is short and sweet, but I think it segues very well into more complicated algorithms that involve checking for specific cases and catching them using conditional statements.

Next week, I’m going to try and explain recursion!
How to Reveal Your Inner Writing Voice
By: Around With A
Tags: Writing, Ideas, Improvement, Development, Creativity

First, your inner voice is about knowing yourself, your powers, and your weaknesses. Once you discover who you are and let others participate in this self adventure, you are a step away from creating your voice.

Start to describe yourself, or if this is a little bit hard for you, ask somebody to help with that. What are the words that best describe your personality? Ask yourself this question.

I find it very difficult sometimes to describe myself. This comes from a lack of self-confidence in my power of doing something.

Discovering your writing inner voice is not something to deal with within 5 seconds. It takes time, but depends on how involved you are, on how much patience you have on succeeded it.

Second, try to get through each written line. How do you feel about it? Is this something I would like to read?

Creating this conversation with your inner writing voice helps to put yourself in the reader’s mind. To ask questions.

If you practiced writing you have already met your voice, so you have a clue about how it’s like to put your ideas on a blank page. At the beginning is frustrating, you believe your writing voice is not that trained as you would like to. Things get better with time.

Freewriting helps your inner voice to escape. Let your mind and voice talk freely and check the results. You might be amazed by what unconsciousness can create. Just let go of prejudice.

What is your inner voice telling when you are writing? Has a happy, pleasant tone or is nervous and afraid? Sometimes I feel overwhelmed and tired. My words seem without any logic and force, but there are also sunny days on my street.

Revealing your voice through writing is an opportunity. Sure, we can all express verbal freely, but writing is more cosmetic.

When we want to express ourselves verbally, we choose our words but not in a way that sounds very pompous, we just want to communicate. But, in writing, we want to express an idea that sounds beautiful and stays imprinted in your mind.

Writing is for beautify ideas.

Your inner writing voice creates your brand. You get to know a writer because her/his inner voice has drawn your attention.

It is very important to speak out loud in your writing. You became a person who has a strong inner voice. Good to be read!

Your ideas are what matter and your writing to express them.

This is what differentiates us.

Everything consists of the naturalness of the language and the ease of transmitting them. And a note of humor to spicy up your words.

Your voice has to be sincere and worth reading it. Showing your sincerity means exposing yourself to readers and set a connection with them.
Princess, monster, or both?
By: Sabrina Ki
Tags: Fairy Tale, Mythology, Iran, Book Review, Books

This was, and this was not, a fairy tale retelling. Inspired by the myths and legend of Bashardoust’s culture — yet still a compelling original story — Girl, Serpent, Thorn was twisted, snakelike, full of nuanced characters in a highly atmospheric setting recalling ancient Persia.

There was and there was not, as all stories begin, a princess cursed to be poisonous to the touch.

As the book advances, the characters make terrible mistakes, with suitably terrible consequences. These catastrophic errors do not belong only to our protagonist Soraya, willing to do anything to break her curse and rejoin society as a ‘normal’ person. Almost everyone in this novel blunders around, entangling themselves ever deeper into nets of their own chaos and regret.

‘Girl, Serpent, Thorn’ by Melissa Bashardoust, will be published 7th July 2020 (Hodder & Stoughton).

Everyone is trapped in their own way, but all retain their agency. This made for incredibly complex characters; I loved the will-she-won’t-she dynamic as Soraya teeters on the needle of her moral compass. Soraya’s mother, Tahmineh, is especially fascinating.

The female bonds in this book were great to read — not least the sapphic romance. It was tenderly written yet no less intense for it, and I loved how it developed. I enjoyed the lack of girl-on-girl hate.

There was, and there was not, a love triangle. As someone who passionately hates most love triangles, the dilemma in this novel was actually quite understandable.

The world of this novel, Atashar, is full of magic, tradition, deities and demons, Persian mythology and Zoroastrianism. I recommend taking the time to read the Author’s Notes at the back, though Bashardoust’s exposition and context meant the world took form around me almost seamlessly, without the need for info-dumping.

Needless to say that after reading ‘Girl, Serpent, Thorn’, the archaeologist in me is dying to learn more about Persian history, and Bashardoust’s other novel, ‘Girls Made of Snow and Glass’.

An advance copy was provided by Netgalley and Hodder & Stoughton in exchange for an honest review.
In Pictures: Dambusters take to the skies with US Marine Corps
By: Ministry Of Defence
Tags: Aviation, United State Of America, Military, Photo Essay, Nato

In Pictures: Dambusters take to the skies with US Marine Corps

US F-35 jets from the Wake Island Avengers launched from HMS Queen Elizabeth alongside the UK Dambusters, as part in Exercise Joint Warrior, the largest multinational exercise hosted by the UK

The jets from the US Marine Corps and the Royal Air Force took part in air-to-air combat scenarios before taking a pit-stop with the Voyager to refuel.

The Voyager provided ‘petrol-station in the sky’ support to the jets offering fuel and enabling them to stay in the air for longer.

Exercise Joint Warrior is the largest multinational exercise hosted by the UK and sees more than 6,000 soldiers, 81 air assets, 28 ships and 130 ground troops from 11 nations coming together to improve the way they respond to current and future threats.

📸 Here’s their pit stop in pictures👇
Help me build a network
By: Madhavan Malolan
Tags: Entrepreneurship, Networking, Life Lessons, Management, Startup

I tried building a network by attending networking events. Very soon realized that it was a waste of time.

Restricting the people in my professional network

I’m very picky about whose advice I take. I realize there are a lot of people trying to seem smart by knowing-it-all. It’s hard to spot their fakeness.

The only filter that works is knowing them and talking to them over years.

I have only 5 such people in my network with whom I share and talk about all things professional. It is only their feedback I genuinely hear.

Nurturing relationships

For people whom I trust, I go out of the way to help them out. I don’t try to look for any business incentive. My incentive is keeping the relationship alive and strong.

What if they ask for help that is too big for you to oblige?

I outright refuse. But this rarely or never happens. All people in my network are very well aware of what I’m doing and where I’m placed to help them out. The filtering of whether I’d be able to help happens even before I’m reached out to.

Picking people

I look up to people smarter than me. By 10x. People who make my jaws drop. There are a lot of such people. They’re just scattered.

I look to have one strong relationship in each domain I deal with. My rough counting tells me there are about a dozen fields I operate in. From design to tech to legal to growth. But I have only 5 people in my network. What about the other 7?

I am still looking for such people whom I can fallback upon when I’m stuck without fear of getting judged for the other domains.

Spotting smart people

The single biggest determinant in figuring out if a person is smart is if they ask hard questions. Questions to which I don’t have answers, or have had difficulty in answering in the past.

If someone asks a dumb question, I try to see what context the other person is missing that demands a question that looks dumb. I give little margin for error. If they’re smart, I indulge in a conversation.

Evolutionary advantage

Science has it that humans are good instinctively at judging people. Hunter gatherers needed to quickly judge whether to allow a person from a different tribe in. They had to do it quick. We’ve been doing this for millennia. We’re good at it. I let my instincts talk when picking people.
비트코인과 이더리움을 뛰어넘을 블록체인 3.0 시대
By: Color Platform
Tags: Color Platform, Blockchain, Cryptocurrency, Ethereum, Bitcoin

in Both Sides of the Table
Review: Inside Out
By: Jp Sebastian
Tags: Pixar, Inside Out, Disney

It’s kinda hard for a movie like this to be the one you figure on writing reviews with straight out the gate. You risk unduly HANGING the next 6 months’ worth out of some stupid ‘objectivity’ calculus. Really though, your ‘joy’ aspect does fire real hard on Inside Out. That’s one bright spark in amongst the opaque dreck of other CG-fat expositions hammering hard at a tired, tired fructose-fired neuron. Now I’m tempted to make up lost time and wail like an impotent dummy at the billion dollar march of bigger meteorites, bigger muscles and bigger mutants but I’ll spare that litre of cortisol for another day (Ant Man appropriate?). There are two basic ways Inside Out fundamentally differs.

Structurally: It’s largely set in the mind of an 11 year old girl driven fairly collaboratively by her 5 emotions (Fear, Disgust, Joy, Anger and Sadness). Together they manage how young Riley weaves and stores memories, each recorded on spheres coloured for their associated emotion (disaster threatens when Sadness reluctantly develops the temptation to touch and ‘taint’ the spheres, around the time Riley moves to a new city). It checks in with the corresponding parental devices now and then but it amounts to a road movie to her Joy and Sadness. It involves no start in a shiny lab or classified G-Man agency, then to a jeopardised city, then space, then God firing divine palm-lasers at a galactic repto-cyborg hybrid (apologies Scientologists). It’s an internal voyage between geographic & architectural metaphors of her waking hours, dreams, train-of-thought, imagination, etc.

But I’m making this sound too mechanical, its movements are so light touch. You needn’t actively scratch your head over every detail for significance. Weird as it may sound, pretentious maybe, I found thinking about Inside Out wasn’t just what I was doing in my head; every well strung scene’s kinesis was thought in action. Let’s park that idea though. No joke or ‘landmark’ is milked and little symbolic relevance spoon-fed but there’s a fair amount for even the youngest, card-carrying silly-billies. Here’s where we should thank the natural and honest voicework of Amy Poehler (Joy). Though it’s also her coming-of-age story, Joy’s delivery is perfect, neither star-power-monopolising distracting quotables nor just paying the bills.
Machbox
By: Michael Stalcup
Tags: Surprise, Thesceneandheard, Poetry, Mystery, Quotes

A quiet scene. Then like a war,

I heard a BANG! and on the floor

My tea had spilled and, strange, what’s more,

A hole was burning in the door.
A Chill Wind
By: Jeff Bailey
Tags: Communication, Maine, Storms, Photography, Winter

There is a storm brewing

My optimistic side favors the positive; the worse of Winter is over. But as the wind bites my face and my brain calculates the distance between where I am and the car, the side of me that restrains inappropriate outbursts, chants curses to the low atmospheric pressure, the darkening overcast, and the building humidity.

At the high school this morning, I crossed paths with a parent and as we approached they said, “I’m done with this!” and I acknowledge them saying, “Here we go again!”.”
Find the Most Frequently Occurring Element in an Array With Ruby
By: Dallas Bille
Tags: Arrays, Methods, Ruby, Programming, Hashes

Method 1.

The first method I’ll use converts the array into a hash with values. We assume you understand how to set a hash’s keys and values. What this method does is iterates over the array, sets an element of the array as a key for the hash, and, for each element’s occurrence, increases its value by one. So if it comes across a pet that exists already in the hash, it increases that pet’s value by one, while keeping the key unique.

Here is what the first method looks like:

pet_count = Hash.new(0)

pets.each {|pet| pet_count[pet] += 1}

pet_count.sort_by { |pet,number| number}.last[0]

Let’s break it down a little bit.

pet_count = Hash.new(0)

#creates a new hash, sets its default values to 0. pets.each {|pet| pet_count[pet] += 1}

#iterates each element, sets our empty hashes key to that of a pet. # “+=“ is the operator on the value of a keys occurrence in the hash.

(E.g., the first iteration: pet_count = {“dog” => 1 } . This is the first occurrence of “dog.”)

If our second iteration contains the same element of a key in our hash, then it adds 1 to that key’s value, while keeping the key unique, which is what happens. (E.g. the second iteration: pet_count = {“dog” => 2} . This is the second occurrence of “dog.”)

Our third iteration sets a new key and a new value since the next element in our carols_pets array is new to our hash. Our hash doesn’t contain a key of “cat” so a new key is created and a value automatically set to 1. Now our pet_count = {“dog”=>2, “cat”=> 1} .

To me this is beautiful. It touches on iteration and the structure of hash creation with key- and value-setting in a block. If you are new to operating on arrays and hashes, this is a good method to dissect. It’s also satisfying to view the result. Which is this:

pet_count = {“dog"=>6, "cat"=>3, "bird"=>3, "chinchilla"=>1, "rat"=>2, "hamster"=>2, "snake"=>1, "mouse"=>1, "spider"=>1}

As you can see, our hash is not quite in order.

Now we can operate on this hash to return the most commonly occurring pet, using the method below.

pet_count.sort_by{|pet,number| number}.last[0]

#hash gets sorted by number

Now let's break this down a little bit:

.sort_by is a hash method, and the block is what the hash gets sorted by (number of times a pet occurs).

If we just ran:

pet_count.sort_by {|pet,number| number}

#returns

[["snake", 1], ["spider", 1], ["mouse", 1], ["chinchilla", 1], ["rat", 2], ["hamster", 2], ["bird", 3], ["cat", 3], ["dog", 6]]

The default sorting with this method for integers is low to high so actually the last key-value pair is the most commonly occurring. All you have to do is call the method “last.”

pet_count.sort_by{|pet,number| number}.last

returns [“dog”=> 6]

All you have to do is add on [0], which operates on an array index number.

pet_count.sort_by{|pet,occurrences| occurrences}.last[0]

returns "dog"

There we go. We have our most popular pet. It’s a little lengthy and complicated, though.
3 best-read Svelte blogs in week 51
By: Jexia S Editorial Team
Tags: JavaScript, Programming, Svelte, Typescript, Software Development

3 best-read Svelte blogs in week 51

Inside and outside of Medium.com.

www.codingwithjesse.com

5 minutes — In July, I started migrating my blog from React to Svelte + Sapper. (I enjoy rewriting React code using Svelte so much, I would do it all day if I could!)

dev.to

5 minutes — Love it or hate it, Eater has a great interactive map listicle (mapicle? 🤔) format. For lists of places, it makes a complicated reading experience simple and fun. I wanted to try implementing it in Svelte.

medium.com

7 minutes — Svelte 3, as most of you know, promises a radical new approach to building user interfaces. Since it is a compiler, it works fundamentally different from other big frameworks. Let’s have a look by creating a retro board in Svelte from scratch.

About this weekly

Svelte Status is a mailing consisting of the latest blogs and tools curated for Svelte pros. I’m Marlos, your curator, working from the Netherlands to help building a cloud platform for front-end developers that is called Jexia.

Do you have a question, feedback or you want to notify me about a recent blog for Svelte devs? Reach out to me via marlos at sveltestatus.com.
Backstage Meditation
By: Benjamin Weinberg
Tags: Poetry, Elementary School

Hair brushed,

shirts ironed,

faces scrubbed.

Eyes forward,

tense,

faces bright under the lights.

Grade five stands in ordered ranks on the risers.

I watched them from the wings backstage.

Voices clear and high:

“I’d rather stand tall

Than live on my knees

And I won’t accept defeat”

I wonder if they hear the words they sing

I remember:

Hurdy Gurdy Man,

Born To Be Wild,

In a White Room,

Sympathy For the Devil.

What did I know in fifth grade?

I closed my eyes and thought:

Every year is like a song.

Some notes sound with such clarity and joy

we hate to let them go,

hold on to them as long as breath allows,

even pause

waiting until the last lingering echo fades.

Others rise up out of deep wells of silence,

lonely and desperate as the cry of a child in the night.

We hear them and hurry home,

suddenly uncertain.

Sometimes our voice calls out alone

quavering, questing.

So many songs set forth

like ancient ships on uncharted seas.

Where they rest,

we’ll never know.

Other times a note is sounded,

picked up and passed along,

voice by voice the chorus gathers

a simple tune become a trend

then the fashion

and in their fashion

others join

making a swelling torrent.

Carried so far from where it started.

Until years later you hear it sung by children

Or piped outside to a parking lot where no one even knows the language.

Thus, in the half-life of social decay

do the isotopes of anger and outrage

disintegrate into lighter elements,

entertainment, amusement,

a host of saccharine substitutes

instead of truth’s harsh bitter sweet.

So many melodies begun

years like pages turned.

From afar, perhaps,

our songs are the faintest rustlings,

no more than waves of wind

from the passing wings of a kaleidoscope of butterflies.
Responsive Web Design
By: Amy Ann Franz
Tags: Responsive Design, Programming, Front End Development, Web Design, CSS

Media Queries

Media queries allow you to add or change CSS depending on whether the condition of the media query is met. For example:

This says to run the code if the viewport if smaller than 600px. This is not a good example of a real-life application, as a program is very unlikely to change colours depending on the viewport size. A more realistic example is displaying a hamburger if the width is smaller than 480px (phone size in portrait mode). If the width is greater than 480px, then display the menu items in the navbar.

Your basic media query looks like this:

@media media type and (condition: breakpoint)

Some examples of media queries are:

Media types: all, print, screen, speech

I’ve listed some conditions below.

max and min-width for specifying device types:

Photo from W3Schools.

And using landscape or portrait :

Photo from W3Schools.

So now that the basics are understood, let's get into applying these principles.

Firstly, a good rule of thumb is to design mobile-first. This is because it usually has the least amount of designing to do, making it easier to adjust as you go. It also makes the media queries easier because you only need min-width rather than specifying both the min and max widths.

What you are going to want to do is create wireframes. Creating wireframes for the desktop allows you to break up different components to understand where you are going to put flex boxes.

Photo by Adrian Cantelmi on Dribbble.

So if you compare the two different designs, you can see the menu changes between a hamburger menu and a normal menu. This means with both components, you are going to have to create and toggle the visibility of the two menus. You will also notice that some items are in rows on desktop and in a column on mobile. For example, “Footwear/Accessories” is where you would add flex boxes and toggle the flex-direction between rows and columns. This makes it really easy to change the layout.

The last thing is changing the font size. There are a lot of different ways to do this, but check out this article for more information.
British Auto Show Makes us Rethink
By: Danillo Almeida
Tags: English, Design, History, Cars, Past

Being born in 1993 helps describe how I started to learn about cars. I grew up surrounded by magazines, posters and sticker albums, so the first ones I could tell apart were Ferrari F50, Jaguar XJ220, and Lamborghini Diablo, to name a few. My family has always been impressed with how I could talk about them even at a low age, especially when I’d skillfully handle the fake questions my father and aunt would ask to tease me. However, those talks often had an anticlimactic end: What’s your favorite car?

Over the years, I learned that the supercar of the moment was the answer that would most easily avoid an awkward moment but, to tell the truth, I’ve never been fascinated with what I now refer to as superlative models — performance coupes, flashy limousines or rugged pickups. I admire them for many reasons, sure, but I’ve always been thrown off by how “unrealistic” they are: expensive, suitable in few environments, and/or easy to become obsolete. This is why the topic of this story has surprised me so much.
🔥 4 Fun Facts About Your Medium Profile ✍️
By: Dr. Derek Austin
Tags: Marketing, Writing, Blogging, Medium, Writing Tips

🔥 4 Fun Facts About Your Medium Profile ✍️

Did you know you can use an animated GIF for your profile image on Medium? Let’s start a trend 🤩

1 — You can use GIFs for your profile image

Medium will accept an animated GIF for your profile image, reminiscent of Harry Potter’s moving newspapers. I made one with my webcam using:

2 — You can put links in your profile

Any links in your Medium profile will be clickable from your profile page. Since you only have 160 characters, I’d leave off the “www” to save space. Remember you only have 80 characters for readers on the mobile app:

3 — You can use emojis in your profile and your username

I’m an ESL student — emoji as a second language. 😂🤣 Use them to improve your profile! I get all my emojis with the Awesome Emojis tool:

4 — You can change your Medium username

It’s free to change your Medium username. Note that your old profile URL will not redirect to the new URL, but all your posts will still work fine.

I hoped you enjoyed these fun tips! 🔥👏👍😎👑
How To Install and Start Programming With Golang
By: Shailesh Jadhav
Tags: Beginners Guide, Golang, Backend Development, Web App Development, Installation

Go Setup

Installing GoLang on your system Requires Three Steps:

Downloading the installation files from the link. Installing the packages Verifying the GoLang installation by running programs

Installing on Linux system:

Extract .tar.gz file downloaded from the above link to /usr/local

sudo tar -C /usr/local <go_tar_filename>.tar.gz

Add /usr/local/go/bin to the PATH environment variable.

export PATH=$PATH:/usr/local/go/bin

Verifying Installation:

Now check Go installation by building a simple program, as follows:

Open a terminal and create the following file structure.

$ mkdir golang/src/test

Now change the directory to the above path.

$ cd golang/src/test

Now, create a file named test.go and write your first test program.

package main import "fmt" func main() {

fmt.Printf("Installation Successful..!!")

}

Now, save the file and go back to the terminal and run the following command.

$ go build

The above command creates a binary file called test.exe, now run the executable to run the above code.

$ ./test

If the installation had correct, then it prints “ Installation Successful..!!”

Commands For Linux Terminal

Congratulations! The installation had been finished and you are ready Go!
The Somme
By: Martin Rushton
Tags: War, Haiku Hub, Remembrance, Contemporary Haiku, History

Get this newsletter By signing up, you will create a Medium account if you don’t already have one. Review our Privacy Policy for more information about our privacy practices.

Check your inbox

Medium sent you an email at to complete your subscription.
Rebuilding Religious Monuments Across Divides
By: Scott Douglas Jacobsen
Tags: Jordan, Scott Douglas Jacobsen, Monuments, Israel, Religion

Photo by Cristina Gottardi on Unsplash

Jordan’s King Abdullah made an announcement on May 7, 2019, about plans to restore some of the destruction to the Church of the Holy Sepulchre, which has been seen as a monument of civilization to both the religious and the secular alike.

As reported, “The announcement surprised church leaders in Jerusalem who have been unable to reach a funding agreement for fear that a church funding the restoration would make ownership claims to it. Orthodox Church spokesman Father Issa Musleh enthusiastically welcomed the decision in a phone interview with Al-Monitor, saying, ‘The decision of His Majesty King Abdullah II is a dream come true. We have been trying for decades to find a way around the stalemate of who would fund the restoration.’”

The Executive Director of the Hashemite Fund for the Restoration of Al-Aqsa Mosque and the Dome of the Rock, Wasfi Kilani, stated, that the contribution of Abdullah to the restoration of the church represented both trust and appreciation by the king.

Kilani stated, “Both the Palestinian leadership and the major church leaders expressed support and appreciation for the position of the king as custodian of both Islamic and Christian holy places in Jerusalem.”

Abdullah received the Templeton Prize in 2018 with a cash amount tied to the prize of 1.1 million British pounds. He wants to donate an unstated amount to the restoration of the building.

Patriarch Theophilos III, according to the Jordan news agency Petra, said, “[The] king’s personal commitment to the security and future of Jerusalem as the custodian of Islamic and Christian holy sites in the city” is shown here.

The deterioration of the church has been seen a major problem with the need for some updates and repairs, or restoration. It has been over 200 years according to reports. With this, several interested or intrigued parties find the donation by the King important as a cultural, at a minimum, contribution.

A Palestinian Christian historian and the head of the Islamic-Christian Commission in Support of Jerusalem, Hanna Issa, stated, “There were many reasons why they agreed. The deterioration of the church had reached a dangerous level that required action and the recent moves between Catholics and Orthodox — which were reflected in the historic meeting in February 2016 between the Pope and the [Russian] Orthodox patriarch — also helped.”

Photo by Cristina Gottardi on Unsplash
The Vampire Lover — John Badham’s Dracula
By: Manor Vellum
Tags: Film, Writing, Horror, Éditorial, Dracula

In the first article from the Out of Time: 1979 and the Last of the Gothic Vampires series, we explored Werner Herzog’s Nosferatu: Phantom Der Nacht (1979), a spare, understated, and decidedly “un-Hollywood” film. John Badham’s Dracula, released in July of 1979, could not be a more different telling of the Dracula legend. It is big and lavish, slick and very “Hollywood” in style. In Nosferatu, Dracula is repellent, like a rodent. In Dracula, he is suave, handsome and positively dripping with sex-appeal. One thing that both films have in common, however, is that they are both, at least ostensibly, remakes: Nosferatu of F.W. Murnau’s 1922 masterpiece and Dracula of the 1931 Tod Browning classic starring Bela Lugosi that launched the first Universal Monster cycle.

Both the 1931 and 1979 versions of Dracula are based on the play by Hamilton Deane and John L. Balderston, and both Bela Lugosi and Frank Langella (the Dracula of the 1979 version) starred as the lead role in the play on Broadway. This is where the similarities end.

Film poster for Dracula (1979).

The screenplay for the 1979 version by W.D. Richter takes a great deal of liberty with both the play and the original Bram Stoker novel, though this was hardly unusual. The plot structure is very different, completely excising the famous Transylvania sequences found at the beginning of practically every other major adaptation. This film instead begins with a bang, right in the middle of a storm at sea as Dracula is being transported by ship from Romania to England. When a sailor’s throat is torn open during the sequence, we are quite certain that this will not be the subtle and suggestive horrors of the Lugosi version but something much more modern.

Perhaps the most modern element of the film is Langella’s portrayal of Dracula himself. He seems to be very conscious to play the character completely opposite of Lugosi as possible. There is no eastern European accent, no slicked back hair, no stern and commanding mannerisms or harsh stares that make the Lugosi version so iconic and unforgettable. Christopher Lee seems to have made some similar choices twenty years earlier when he took on the role, but Langella takes it a step further by playing the vampire much more like Heathcliff from Wuthering Heights or some other tragic romantic hero of gothic literature. Though Lugosi is magnetic partially because he comes across as exotic, Langella is simply charming. He does not need to attack his victims or sneak up on them in their sleep, Mina and Lucy are drawn to him and give themselves over willingly. “I come of my own accord,” says Lucy, played beautifully by Kate Nelligan in the film.
Why It Hurts To Be TOO Specialized As An Entrepreneur
By: Avneet Ghuman
Tags: Entrepreneurship, Business, Entrepreneur, Intelligence, Education

I applaud masters degree holders, PhD’s and other students of higher learning. Despite their astounding intelligence and penchant for learning, their higher-than-average IQ and ability to synthesize information and research might be hurting them in business.

I believe higher learning creates an ecosystem of entitlement and “boxed-in” thinking. Often times, we believe that because we did well in school and checked all the boxed on our report-cards that we will get the job of our dreams and become “upper-middle class” overnight. And while this is true for many people who achieve their upper-middle-class dreams through higher education and a 9–5 (more like an 8–8), I find that this system often makes it hard for many of these boxed-in thinkers to transition to entrepreneurship.

Entrepreneurship is fostered by making shotgun decisions with just enough information with the right amount of delegation. The truth is that you cannot know everything by yourself and you cannot be an expert at everything, but you can know just enough to make sure you pick the right person to help you get the job done right. Because if there’s anything I’ve learned in life as an entrepreneur- sometimes you just have to pull the trigger and do the dirty work.

I’ve ran into the issue where many of these highly educated people believe they are above the baby steps involved in creating a business from infancy. Because they went through years of sacrifice and research, they feel they are ready and well-equipped to handle the large, executive style decision making that comes with a big business. But in order to get there, you must master what it is like to be a humble entrepreneur and do the little stuff. You have to be customer service, the postman, the janitor, security, sales rep and bookkeeping. Being an entrepreneur is a PhD in humble beginnings. And if you want to be successful, you have to understand that your business will not blow up overnight because you wrote a successful news article or social media post on your business. Your business will only thrive and have that “blow up” moment because you did all the little first steps right. Your business will not have a chance to get exposure and cater to the new demand if you haven’t first created the logistics and ability for the business to scale and meet that demand you hope for in the first place.

So, when you’re building a business- throw your formal education out of the window. Throw everything you know about business from a textbook out along with your formal training. Because in order for you to take your business to the next level is nothing more than a humble “can do” attitude, flexibility and some elbow grease.

XOXO

Avneet
You.
By: Keith R. Higgons
Tags: Heartbreak, Love Letters, Short Story, Fiction, 100 Naked Words

Would you want to hear what I have to say?

I don’t think so.

It’s better this way.

You keep your life.

I’ll keep mine.

Mergers are messy.

On this, we can agree.

What’s that?

It’s not that I don’t want to tell you.

It’s that you don’t want to hear.

It’s not a lack of desire.

I’ll take it as it comes.

What’s that?

I understand nothing is forever.

There will be another.

There always is.

It just won’t be you. And that’s what sucks.

Until then, you’ll enjoy me.

Until then, I’ll enjoy you.

As it should be.