- Joined
- Jun 11, 2012
- Messages
- 117
- Reaction score
- 3
- Primarily Uses
As you know I am a newbie in programming as I progress learning, I find many things do not make sense often cause confusion for me. So, here I will save all what cause confusions in the programming language that could have done better to avoid. I save this so someday If I am capable of create a new programming language I will use these as preference.
The programming language I will construct (in the future when I mastered programming language ) called Noob Plus or N+
Philosophy of the language: Human Readable, Avoid Confusion and can Visualize, with everyday use English.
The terminology of the language: When you first get to learn the language what you need to learn is not the syntax but terminology. Programming language use all sort of scientific or terminology such as Variable, Iterator, Array, Method...etc. . We can eliminate or burn this step that to make it easier for anyone to learn the programming. We replace it with the everyday English usage, something that everyone can visualize it in their head instead of memorize it does.
1. The container: in this new language we don't call variable as variable instead we call it container. The variable actually If visualize it looks like a container or a box where you can put your stuffs in. We call it container. The way we define container and assign stuff in like this.
Container << "Computer"
We don't use = as assignment. Why? When I first look at the language I always think of it is an equal sign, still now I still sometime picture it with the equal sign in math. Why dont we use something else that when newbie look at it they can visualize something in their head. As you see the example above, you can see that Computer goes into the Container to store it.
With the << replace the = we are now free to use = for something else which make more sense when read by people with non programming background. For example the control flow.
If Today = Monday
Rain
2. The Cell Container or Large Container: The Array, if you visualize it in your head, it looks like a variable but you can store more stuffs in it. So we just call it Cell Container or Large Container instead of Array. Because non-programmer when first read they can visualize the object they familiar with, something they see everyday instead of having to learn the new terminology Array. Also we try to group similar things in the same category to make it easier to understand and visualize
CellContainer.size[30]
The example above is when we define an Array with the size of 30. We don't call the number inside the array as Index. We call it Cell. So when we read the array is like this a cell container has 30 cells or the size of large container is 30. You can visualize it in the head, a large container divided in 30 smaller cells means you can put 30 more computers in it.
How do we access this container?
CellContainer.get[10]
When you read it is like this, get the cell 10 in the cell container. How we access or iterator the Array. We can use this
CellContainer.get[ALL]
Above return all the stuffs in array.
CellContainer.where["Computer"]
Above search for specific object, instead of use loop or iterator to go through each we use where and that is it.
CellContainer.append["Table"]
Above, how we put more stuff in cell container.
==============================================================
Lets recap. Instead of learning terminology and to understand what them do Ex. Variable and Array, Index. We can just simply group these two in same category because they have similar straits and just call it Container for variable and Cell Container for Array, the the index we call it cell.
When we assign something we use << instead of =, because = often lead people to confuse with math or equal. It is not equal is more like you put something to store. So we pick the symbol best demonstrate for assignment. By doing that we also eliminate another confusion comparison operator equal ==. When non-programmer read it they will not have to wonder what this == does
Next time I will talk about the Hash.
Now what do you think of the idea of this new programming language
The programming language I will construct (in the future when I mastered programming language ) called Noob Plus or N+
Philosophy of the language: Human Readable, Avoid Confusion and can Visualize, with everyday use English.
The terminology of the language: When you first get to learn the language what you need to learn is not the syntax but terminology. Programming language use all sort of scientific or terminology such as Variable, Iterator, Array, Method...etc. . We can eliminate or burn this step that to make it easier for anyone to learn the programming. We replace it with the everyday English usage, something that everyone can visualize it in their head instead of memorize it does.
1. The container: in this new language we don't call variable as variable instead we call it container. The variable actually If visualize it looks like a container or a box where you can put your stuffs in. We call it container. The way we define container and assign stuff in like this.
Container << "Computer"
We don't use = as assignment. Why? When I first look at the language I always think of it is an equal sign, still now I still sometime picture it with the equal sign in math. Why dont we use something else that when newbie look at it they can visualize something in their head. As you see the example above, you can see that Computer goes into the Container to store it.
With the << replace the = we are now free to use = for something else which make more sense when read by people with non programming background. For example the control flow.
If Today = Monday
Rain
2. The Cell Container or Large Container: The Array, if you visualize it in your head, it looks like a variable but you can store more stuffs in it. So we just call it Cell Container or Large Container instead of Array. Because non-programmer when first read they can visualize the object they familiar with, something they see everyday instead of having to learn the new terminology Array. Also we try to group similar things in the same category to make it easier to understand and visualize
CellContainer.size[30]
The example above is when we define an Array with the size of 30. We don't call the number inside the array as Index. We call it Cell. So when we read the array is like this a cell container has 30 cells or the size of large container is 30. You can visualize it in the head, a large container divided in 30 smaller cells means you can put 30 more computers in it.
How do we access this container?
CellContainer.get[10]
When you read it is like this, get the cell 10 in the cell container. How we access or iterator the Array. We can use this
CellContainer.get[ALL]
Above return all the stuffs in array.
CellContainer.where["Computer"]
Above search for specific object, instead of use loop or iterator to go through each we use where and that is it.
CellContainer.append["Table"]
Above, how we put more stuff in cell container.
==============================================================
Lets recap. Instead of learning terminology and to understand what them do Ex. Variable and Array, Index. We can just simply group these two in same category because they have similar straits and just call it Container for variable and Cell Container for Array, the the index we call it cell.
When we assign something we use << instead of =, because = often lead people to confuse with math or equal. It is not equal is more like you put something to store. So we pick the symbol best demonstrate for assignment. By doing that we also eliminate another confusion comparison operator equal ==. When non-programmer read it they will not have to wonder what this == does
Next time I will talk about the Hash.
Now what do you think of the idea of this new programming language
Last edited by a moderator: