Have you ever wondered how a computer executes our requests? Nowadays it seems normal to type a letter and see it directly appear on the screen: partly due to habit, it may seem an extremely simple operation, but it is much more complex than it appears.
The computer speaks its own language, which is not English or Italian, but machine language. This language has an alphabet called binary, consisting of only two symbols: 0 and 1. Programs written in binary code are directly executable by the computer, but they change according to the type of processor. Therefore, there is no single machine language, but all of them are still unintelligible to humans.
01001000 01100101 01101100 01101100 01101111 00100000 01010111 01101111 01110010 01101100 01100100 00100001
Esempio di linguaggio macchina, in binario. Convertito in testo utilizzando la codifica ASCII risulta in un semplice “Hello World!”.
As can be guessed, over the years, various programming languages have been introduced in order to communicate with the computer. These act as a conduit between human and computer language; as a result, they are not directly executable but require translation into machine language, carried out directly by the compiler.
In simple terms, coding is thus about providing precise instructions to computers through programming languages.
At a basic level, a code can tell the computer to change columns in a table, join various data sheets, and can be useful for doing analysis or creating charts based on the data we have. If implemented, however, this enables the creation of software, applications and websites; tools that are now essential in everyday life.
It ranges from data management to video game creation, from smartphone apps to complex systems used in businesses. Coding underlies many of the technologies we use on a daily basis.
I videogiochi sono solo una delle tante applicazioni del coding alla vita di tutti i giorni
Programming languages are many and are constantly developing, each with specific functions and a different degree of difficulty, just as it may be easier for us to speak Spanish and more difficult to learn Mandarin.
Today we can benefit from the development of high-level languages, for example Python, which contrary to what one might think, are the simplest languages; in fact, by high-level we mean a high degree of differentiation from machine language. They have a syntax that is more natural and more in line with human language and are often used for data analysis and development of websites and applications.
print (“Hello World!”)
Esempio di Python
Getting more and more specific, we can count mid-level languages, such as C. They are more complex in syntax and require a deeper understanding. Since C is an open source language it allows those with the skills to create new versions by going on to modify the structure of the language itself, thus languages such as C++, C# (C-Sharp) and Objective-C, the latter developed by Microsoft and Apple, respectively, were born.
These are often used for software development-for example, many components of Microsoft Office are developed in C++. Microsoft Office code, however, is “closed”-a.k.a. “proprietary software”-which means that it is not available to the public for review or modification but only developers authorized by Microsoft can access and modify the source code. This allows Microsoft to protect intellectual property and control the distribution and use of the software.
#include <iostream>
using namespace std;
int main()
{
cout << “Hello World!” << endl;
return 0;
}
Esempio di C++
Then, there are the low-level languages, such as Assembly, which are instead more difficult to learn. Assembly is very close to machine language, which means that each instruction corresponds directly to an operation that the CPU, the “brain of the computer,” can perform. It is often used to optimize performance and manage hardware operations.
The choice of language depends on your personal goals and the application you want to develop. Python, for example, is very popular because of its simplicity, but languages such as C++ are better suited for applications where speed and security are critical.
Today, talking about coding inevitably means exploring artificial intelligence (AI), particularly generative intelligence. This technology advances through machine learning, allowing computers to learn from data and generate original content such as text, images and music. Models such as ChatGPT and DALL-E are examples of how AI can continuously create and improve, adapting to new inputs.
Applying Generative Artificial Intelligence (GenAI) to coding means revolutionizing the way we program, making code writing easier and more accessible even to the less experienced. Indeed, whereas early programmers had to consult lengthy documentation, today, thanks to these tools, the process is much more straightforward.
Nowadays, it is possible to write a prompt directly in natural language. ChatGPT, which acts as if it were an expert capable of instantly consulting thousands of Internet sites, will provide us with output that, inserted into the script of programming languages, can be understood by the computer.
For example, I could ask ChatGPT to act as a Python expert, writing parts of code or identifying a possible problem; in fact, if an error code appeared on Python, ChatGPT could help me identify what kind of error I made.
Thus, coding is the basis of intelligent software development, but in turn it will benefit from the evolution of AI, creating a virtuous circle that is transforming the technological world. Indeed, Python code was written to create ChatGPT, but now it is ChatGPT that helps create and improve Python codes.
Another type of GenAI that should definitely be considered is GitHub Copilot, a programming assistant that suggests code as we write. It is integrated into editors such as Visual Studio Code (Python) and uses artificial intelligence to understand the context of our work. Based on large amounts of public code, it offers suggestions to speed up the writing process and help avoid mistakes.
However, it is important to remember that we cannot blindly trust what artificial intelligence suggests; in fact, some controversy has arisen over the years regarding the information provided by artificial intelligence.
One prompt in particular had become famous that asked DELL-E, a type of artificial intelligence that can generate images, to create an image of an empty room “without any elephants.” The artificial intelligence, which was much less developed a few years ago than it is now, invoked the concept of an elephant and generated an image of a room with an elephant in it. This phenomenon in which artificial intelligence generates false or inaccurate information that appears plausible is called hallucination.
Today, repeating the experiment with DELL-E 3, the updated version of DELL-E, the image that is generated is indeed that of a completely empty room.
It is important to keep in mind that artificial intelligence is constantly evolving; in fact, new, more up-to-date, higher-performance models are being created and released all the time.
But artificial intelligence, despite its name, does not have a consciousness of its own; it is simply a very powerful tool that can handle large amounts of data and automate complex tasks, but for it to work optimally it requires collaboration between AI and people. Humans, in fact, bring creativity, insight and ethical decision-making. Together, they can solve problems in more effective ways, improving innovation and productivity.
The article Coding is not a fad comes from TheNewyorker.