開源日報 每天推薦一個 GitHub 優質開源項目和一篇精選英文科技或編程文章原文,堅持閱讀《開源日報》,保持每日學習的好習慣。
今日推薦開源項目:《提示 bullet》
今日推薦英文原文:《10 Programming Terms in Normal Human Language》

今日推薦開源項目:《提示 bullet》傳送門:GitHub鏈接
推薦理由:一個在命令行中幫助你處理輸入的 Python 庫,包括屏蔽不合法的輸入和提供下拉列表等等,最近它還推出了滾動條相關的功能——這意味著你可以在下拉列表中提供更多的選項了。當然了,如果你不希望你的下拉列表過於單調,這個庫也給你提供了使用其他樣式的可能性……或者往列表裡加點表情包也是個好選擇。
今日推薦英文原文:《10 Programming Terms in Normal Human Language》作者:Aphinya Dechalert
原文鏈接:https://medium.com/@PurpleGreenLemon/10-programming-terms-in-normal-human-language-7279d94f3cce
推薦理由:對一些編程常見用語的解釋

10 Programming Terms in Normal Human Language

Learning programming is like learning a completely different language. It gets even worse for a person coming into the field to be bombarded by long tutorials littered with words that makes no sense.

All the words below have more than a million words written about them. But we don』t have the brain capacity or time to process such a massive amount of information. Today, I』ve tasked myself with explaining each concept as simply as possible.

So here』s a quick and concise decryption of commonly used words in programming.

1. Immutable

Immutable is another word for unchanged. If a state is said to be immutable, it means that it』s not supposed to change. Whatever value you』ve set is not going written over or have the potential of changing.

In JavaScript, const is a way to partially declare an immutable value. You can still change the value of const but it takes a bit more work and thinking than let and var.

2. Object

An object is a structured set of code written in a certain way to specify a set or category of things. It is a blueprint for an instance of that particular thing.

People use objects to create more of the thing. They create new objects, assign values to it and use the methods (aka written functionality) to do things with the instance of the object.

3. Prototype

It looks like an object. It smells like an object. People often mistake it as an object. But it』s not an object.

A prototype is the instance itself but replicated. While an object is the plan for the thing, a prototype is the thing with the ability to be extended with features.

The easy way to get your head around it is that an object gets used to create and a prototype is used to create.

4. First Class Function

A function that』s treated like a variable.

This means you can have a function inside a function and set it up like a variable.

5. Recursion

A function, procedure or algorithm that calls itself.

For example, a for loop is a recursion. Main component of a recursion is the thing that kick starts it off and a condition that ends it — or else it will just keep calling itself until the program crashes.

6. Encapsulation

The thing that ring fences off a group of methods or data from outside access.

Encapsulation keeps things local and private inside a conceptual box.

7. Polymorphism

The ability for that same thing to be lots of other things.

For example, an object is polymorphic because it is a blueprint where unique variables can be set for multiple instances of it.

Cats are polymorphic. They』re all still cats but with different appearances and personalities. A stormtrooper』s armor, however, is not polymorphic because they』re all the same.

8. Inheritance

The same concept as inheritance with money.

The child inherits whatever the parent has/is. Inheritance is the act of the child taking on the values and properties of the parent.

In most languages, inheritance flows inwards — meaning that the flow of inheritance goes parent to child and not the other way around.

9. Data Type

Naming what kind of data it is you』re setting.

JavaScript is a loosely typed language. This means that you don』t have to tell it what kind it of data type it is, you just have to tell it that it』s a value to be stored. This is done through var, let and const.

Java is a strongly typed language because you have to tell it exactly what the thing you』re setting is — that is — boolean, char, short, int, long, float or double etc.

10. Persistence

It sticks around. If you go back to it, the thing is still there.

For example, a declared variable and an instance of an object has persistence because it』s still there if you call it again.

Final Words

If you can』t explain it simply, you don』t understand it well enough - Albert Einstein All the concepts above started off as one liners from their creators. But over time, more words have been added to them to test, extend and expand on the idea. There』s nothing wrong with that either — but that can be overwhelming and intimidating for new developers. I was there myself half a decade ago and I know the feeling.

I hope that in condensing it back down, it』s made life a little bit easier for you.
下載開源日報APP:https://openingsource.org/2579/
加入我們:https://openingsource.org/about/join/
關注我們:https://openingsource.org/about/love/