The basic structure of a program consists of "only three" elements: "Sequence," "Selection," and "Iteration" [Excel Macro #QuoteNote70]
The quote I would like to introduce this time is as follows!
The basic structure of a program consists of
"only three" elements: "Sequence," "Selection," and "Iteration"
Rather than just a quote, this is a basic structure that anyone who does programming should definitely know. Even for those who say, "I don't do programming," opportunities to encounter programming are bound to increase rapidly in the future. I will explain the reason in the next chapter.
"Sequence," "Selection," and "Iteration"
The basic structures of programming are "Sequence," "Selection," and "Iteration." Let's take a look at what they entail.

Sequence:
This is the most basic flow where a program is executed from top to bottom in the order it is written. Unless there are special instructions, commands are processed one after another. It is simple to remember as "in order."

Selection (Branching):
This is a structure that switches the process to be executed depending on whether a certain condition is met. It is simple to remember as "if this, then that."
-
if-else statements (if this, then A; otherwise B)
switch-case statements (branching into various cases depending on the value), etc., fall under this category.

Iteration (Looping):
This is a structure where a certain process is executed repeatedly multiple times. It is simple to remember as "repetition."
-
for statements (repeat a specified number of times, or repeat for each element in a collection)
while statements (repeat while the condition is true)
do-while statements (execute at least once, then repeat while the condition is true), etc., fall under this category.

Why you should grasp the basic structures of programming

Even if you are not currently involved in programming, the reason why you should grasp the basic structures of programming as soon as possible is...
It is because, with the advent of free-to-use AI tools like ChatGPT and Gemini, it has become possible to have AI generate programming code by simply describing what you want to do in text.
Given that commercials with phrases like 'you can program without code (no need to write code)' are flooding the streets, there is no doubt that this trend will accelerate.
A future flooded with automatically generated code created by AI roots

In particular, for VBA (commonly known as macros) which can automate Microsoft Excel, or GAS (Google Apps Script) which can automate Google Sheets, it is easy to imagine that code generated using AI tools will be implemented in many workplaces.
For example, although there isn't much work like this in practice, suppose you are given the instruction, 'Color every other cell yellow from A1 to A100 in Excel.' The 'every other' part is the key; processing like this, where Excel's filter functions cannot be used, is very tedious to do manually.
However, if you use an AI tool, you can generate the code in an instant. Below is a case where I had Gemini create the code.

All you have to do is paste this generated code into the Excel VBE and run it, and the cells from A1 to A100 will be colored yellow every other cell.
Both Excel and Google Sheets are essentially spreadsheet software, but since the essence of all business is 'input -> processing -> output', spreadsheet software like Excel and Google Sheets plays a major role in various workplaces every day in the 'processing' part of this process.

The digital native generation, who have had the internet and digital devices around them since childhood, are reaching the age where they are increasingly entering society. Among these digital natives, the Z generation, generally born between the late 1990s and early 2010s, tends to be very concerned about 'Taipa' (time performance).
Taipa is a term that expresses the effect or satisfaction relative to the time spent. If you get high results or satisfaction in a short time, it is described as 'good Taipa', and conversely, if the effect or satisfaction is low despite the time spent, it is described as 'bad Taipa'. Centered on the Z generation, there seems to be a strong tendency to use time efficiently and to try to obtain a lot of information in a short time.
Work can be automated by generating code using AI tools
The Z generation, who will be active in society from now on, values Taipa
The prediction derived from these two points is a disastrous situation where 'code generated by AI without understanding the structure will flood into the workplace'.
The disaster caused by AI-automatically generated programs

The reason why the situation where programs (code) generated by AI tools flood every workplace is a disaster is that because the person who implemented it does not understand the content, there is a possibility that they will not be able to fix the implemented programming code when minor changes or irregularities occur.
There is an unwritten rule, or perhaps an implicit rule, that once work is made efficient, new work is given in the time that has been freed up. It is the sad fate of capitalism. Once a task is automated, the net time that task takes is considered to be the time of the automated task, so if the automation code used daily stops working, the day's work will simply be delayed. It's not that a plus becomes zero, but that zero becomes a minus. You aimed for automation by valuing Taipa, but it's putting the cart before the horse, isn't it?
However, I don't think there are many people who, despite grasping the overall picture of this situation, implement code they don't understand using AI tools while being prepared for the disadvantages when irregularities occur. In most cases, they don't think as far as when an irregularity occurs, and they just reach out for code generation by AI tools with the sole desire to automate the work in front of them.
'If you can't explain it, you don't understand it.'
That is a famous quote by Einstein. Even just one quote left by a genius is excellent.
'Someone' must maintain the automated system

Once a task is automated, that task is considered to be in its normal state when automated. If an irregularity occurs, someone must fix the code. If no one can fix it, it is the worst-case scenario, but you can return to the manual processing before automation, but there is no doubt that the evaluation of the person who could not handle it will go down.
In some cases, code automatically generated by AI may be used for quite critical business operations. It is also possible that the situation has become so automated that people have forgotten how to perform the tasks manually, making it difficult to revert to manual processes.
Yes, in many cases, the automation code that is so highly valued must be maintained by someone.
Regardless of whether it was automatically generated by AI or not, if the person who understands the content of that code leaves the organization, someone else must take over the role of maintenance. It is highly likely that the amount of code requiring maintenance will explode in the future, due to the emergence of AI tools and the entry of Gen Z into the workforce, who use these tools without hesitation...
The quote I introduced this time is useful in such situations.
The basic structure of a program consists of
"only three" elements: "sequence," "branching," and "iteration"
The longer and more complex the process you want to automate, the longer and more complex the program code becomes. However! The processes actually executed by the code can be broadly divided into "only three" elements: "sequence," "branching," and "iteration".
No matter how long and complex the code is, what it executes is a sequence of results from each line of code. Each line of code is always one of "sequence," "branching," or "iteration". The phrase "the program isn't working" is too low-resolution to describe the problem of an automated system not working as intended. In reality, the problem of "the program isn't working" is always a state where one of "sequence," "branching," or "iteration" is not working as intended on some line of code.
If you understand this, the chances of being able to fix a program that has developed a bug will increase significantly. Even if it is not code you wrote yourself, it becomes easier to guess where the bug is occurring.
Certification exams are also recommended

To grasp the basics of programming, I also recommend taking on a certification exam. I am the type of person who cannot work hard at all without a deadline, and if money is involved, I can exert more concentration than my own willpower. I am the type who only truly understands the gravity of a situation in my heart, not just my head, after spending my own money...
I recommend the "Excel VBA Basic" exam. VBA stands for Visual Basic for Applications, which is what macros are. In short, it is an "exam regarding basic knowledge of Excel macros."
Just because you pass this exam doesn't mean you will be able to write macros from scratch, but your understanding of "sequence," "branching," and "iteration" will deepen, and it covers basic programming knowledge about how programs are executed.
Since it is a CBT (Computer Based Testing) format, exams are held every weekend at local computer schools. Regarding study, there is an official textbook, but for the Basic level, you can reach a passing level by watching videos explaining it on YouTube several times and solving mock exams found online a few times.
Recently, as Tsumitate NISA has become popular and hometown tax payments have become common, the importance of basic knowledge about money—financial literacy—has been increasing in society. It is easy to predict that the importance of basic knowledge about IT, or IT literacy, will increase even more than it does now.
Among IT literacy, I believe that basic knowledge about programming is particularly important... or rather, it has the best cost-performance. If you are interested, please try taking the "Excel VBA Basic" exam.
This is a video series that carefully explains how to pass the "Excel VBA Basic" exam. ↓
The official textbook is here. After all, it is helpful to have one copy.
If you found this article interesting, please check this out too!
📢 Announcement
Thank you for reading to the end. "Likes" and "Follows" are very welcome! It encourages my activities on Note!
Hello again. My name is Nick. I didn't graduate from university, but I have continued to read and have worked at a foreign-affiliated company for over 10 years. As an ordinary salaryman, I will introduce 'quotes that strike a chord' that I have encountered through my experience of reading over 200 books and in my daily work and life. Many quotes from subcultures such as manga, anime, and movies are also included!
Click here for my self-introduction and main topics! ▼
Click here for the list of famous quotes! ▼
I also dream of publishing a book someday! ▼
いいなと思ったら応援しよう!
読んでいただきありがとうございます。この記事の内容がちょっとでもあなたの人生の役に立てばうれしいです。