Understanding Essential Coding Terminology for Newcomers
Written on
In the series titled "Talk Like A Developer," I strive to empower both technical and non-technical audiences to engage with complex subjects confidently by presenting them in an accessible manner. This post serves as a guide to the fundamental coding terms you will encounter as you begin your programming journey and throughout the "Talk Like A Developer" series.
Introduction:
Greetings! If you're new to my blog, Apart From Blonde, I'm Jess, a recent computer science graduate dedicated to demystifying intimidating subjects. My blog features a segment called "Talk Like A Developer," designed to help anyone—from my 11-year-old sister, who enjoys programming, to my 21-year-old sister, who is into fashion—feel comfortable discussing technical topics. This article will introduce key terminology relevant to that series and enhance your ability to seek help or conduct further research.
Here’s a compilation of essential coding terms you’ll likely encounter:
Programming Language:
Just as spoken languages have varied ways of expressing ideas, programming languages offer distinct methods for writing code. A programming language is essentially a medium through which you instruct a computer to perform tasks. It’s crucial to remember that computers aren't omniscient; they can only execute what we program them to do. They don't generate knowledge autonomously; we facilitate their understanding through programming languages.
Examples include: Python, Java, C, JavaScript, HTML, CSS, C#, among others.
Pseudo-Code:
A popular strategy among developers is to begin projects by outlining ideas in pseudo-code (pronounced sue-doe-code). It’s important to note that pseudo-code is neither a programming language nor software; it’s a simple drafting tool that allows you to express coding logic without the constraints of syntax. If you understand the goal of your code but are uncertain about the specific language or syntax, pseudo-code is an excellent way to jot down ideas freely. For instance:
- English: “I have 3 books.”
- Pseudo-code: books = 3, books: 3, books -> 3, etc. (whatever format works for you!)
- Actual code in Java: int myBooks = 3;
While you might not need to grasp the Java syntax fully, this demonstrates how pseudo-code can bridge the gap between English and code. It's especially beneficial for visualizing complex functions and breaking them into manageable parts.
IDE (Integrated Development Environment):
When crafting an essay, you might utilize word processors like Microsoft Word or Google Docs. Similarly, an IDE is a software application designed for coding projects. As the name implies, it provides a dedicated environment for development where you can write, execute, test, and debug your code—much like how word processors allow you to compose and refine essays. Various IDEs support different languages and offer unique tools. Personally, I favor VSCode for its cross-platform capabilities and comprehensive language support, but IntelliJ is another solid choice, albeit with a steeper learning curve.
Examples: VSCode, Visual Studio, IntelliJ IDEA, Xcode, IDLE, etc.
Functions:
A function is a block of code that performs a specific task. Just like in mathematics, some problems require a single step to resolve, while others necessitate multiple steps. To avoid rewriting all the necessary steps each time, you can encapsulate them within a function and call it with a single line of code. “Calling” a function means instructing the computer to execute the task defined within it. You can call a function as many times as needed!
Sometimes, you can provide a function with information to tailor its execution. For example, if a function's purpose is to add two numbers, you would simply input the two numbers each time you invoke it.
To illustrate the convenience of functions, imagine you create a beloved dessert recipe. Once documented, you won’t need to rewrite it every time you wish to make it; it will be readily accessible in your notes.
A function may also be referred to as a method or algorithm.
Variables:
Just as functions allow you to repeat tasks, variables help you store information for easy reference without retyping it. For instance, assigning a value to a variable might look like this:
appleCount = 20
Here, we track the number of apples I have after shopping, which is currently 20. Whenever I use appleCount in my code, it refers to that value of 20, unless modified.
You might wonder why I would repeatedly type appleCount instead of just writing 20. If I buy five more apples, I could simply write 25, but that involves math, which might be cumbersome in complex situations. Instead, I could adjust it as follows:
appleCount = appleCount + 5
Now, my total apple count is updated, and any changes to appleCount will reflect the latest value without needing to remember it. Additionally, some values might not be known until the code executes, necessitating a variable to store the resulting value.
Loops:
Loops are a fundamental concept in programming, prevalent in nearly every language. They consist of a segment of code that executes repeatedly until a specified condition is satisfied. For example, to determine the length of a word, you might express it as: “take this word, move one letter at a time, and count by one for each letter until no letters remain.” Each letter counted completes one iteration of the loop, and once the condition is met (in this case, exhausting the letters), the loop ceases, yielding the total letter count.
Examples: for loop, while loop
Statements:
A statement is simply a line of code that performs a task. Statements constitute the bulk of coding scripts and can reside within functions, loops, or stand alone. In the earlier example, appleCount is a variable, while appleCount = 20 is a statement.
Syntax:
Syntax refers to the specific rules governing a programming language. As you become proficient in multiple languages, you'll notice varying syntax requirements, which must be adhered to in order to avoid errors. For instance, some languages necessitate ending statements with a semicolon, while others do not. If you attempt to execute appleCount = 20 in a language that requires a semicolon, an error will occur until you modify it to appleCount = 20;.
Running:
This term is straightforward: it simply means executing your code. Common phrases include “run this code,” “try running that,” and “what occurred when you ran your code?” Some IDEs feature a “Run” button, enabling you to execute your code with a click. In IDEs without a “Run” button, you can enter a simple command in the terminal (see definition below) to run your code, which varies by programming language and is easy to find with a quick Google search.
Debug:
Debugging involves the process of identifying and resolving errors in your code. If you encounter an error while trying to run your code, debugging helps you eliminate any bugs until your code runs smoothly. The complexity of debugging can vary; for simple syntax errors, the IDE might directly indicate the issue, such as “statement missing ; on line 1,” prompting you to add the semicolon and re-run your code. In more intricate cases, an IDE may not specify the error, necessitating online resources or classes focused on various debugging strategies.
Terminal:
The terminal is a command interface where you can execute various commands. For instance, if someone instructs you to “run your code” and your IDE lacks a “Run” button, you would access the terminal (often via File -> open Terminal) and enter the relevant command for the programming language in use. Most IDEs come with built-in terminals, and all computers have their own terminal applications. The terminal serves multiple purposes beyond executing code, such as displaying results from functions you are testing and any error messages that occur during execution.
GitHub:
In collaborative school projects, it's common to create shared folders in Google Drive for project materials and team collaboration. GitHub serves a similar purpose but is tailored for programming. In group coding projects, one member creates a GitHub repository (repo) and shares it with the team, allowing everyone to access and contribute to the project.
At a glance, a GitHub repo resembles a shared Google Drive folder, displaying a main project folder with subfolders and files, along with update notifications like “Jess edited ABC file 10 minutes ago.” Like Google Drive, GitHub facilitates storage and access to project modifications. However, unlike Google Drive, editing files directly on the GitHub website is discouraged, as it lacks an integrated IDE for running code. Instead, you would download the repo to your computer, make necessary changes, and then upload the updated files to GitHub. To streamline this process, GitHub offers functionality where a simple terminal command can automate several steps, such as uploading modified files without the need to manually delete old versions.
If you have questions about any programming terms not covered here, feel free to reach out to our technology blog at [email protected]!
Interested in more content from Apart From Blonde? Click HERE!