Do you want to learn how to program?
Do you want to write your own apps and code nice games? Then this is the right tutorial for you.
Get started with this tutorial without any previous knowledge.
Let’s get started!
- 1 Why should I learn to code?
- 2 The basics – getting started without prior knowledge
-
3
Learn programming in 10 steps
- 3.1 #1 Soak up motivation
- 3.2 #2 Writing your first Hello World
- 3.3 #3 Writing according to instructions
- 3.4 #4 Learning to read documentation
- 3.5 #5 Writing Clean Code
- 3.6 #6 Working together in a team
- 3.7 #7 Learn advanced techniques
- 3.8 #8 Self-promotion and coding effectiveness
- 3.9 #9 Putting new technologies into practice
- 3.10 #10 Create novelty and make it usable
- 4 Other beginner questions
Why should I learn to code?
Programming is the key skill of the 21st century.
Software can automate repetitive tasks and do them in a rule-based way. If you can code, you can get your tasks done faster. If you write good, error-free automation, your labour is multiplied a million times.
You may think millions of times is an exaggeration – but accountants used to spend months preparing the annual closure by adding up values by hand. A computer can do the same task in seconds!
Other advantages: You understand how software works and can customise software to your needs. You can fix your computer problems more easily and have more understanding of the errors in other people’s software.
Which PC / laptop do I need?
Unlike gaming, you do not need a fast and powerful computer for coding.
You can code on a 10-year-old notebook or desktop PC. For 95% of the tasks, a notebook or desktop PC with Windows, Linux or macOS and at least 4 GB RAM is sufficient. As a beginner, you don’t need a better computer, because your first software will hardly push your computer to the limit.
If you have a browser running on your computer, there is nothing to stop you from writing your first working app today.
Simple rule
Do I need any prior knowledge?
If you can read and write, then you can learn this skill.
Optional: You can learn this skill faster if you can think abstractly. You don’t need to have a 1.0 in maths at school or have studied computer science. Many professionals have acquired their skill via free tutorials like this one and not in university.
Learn any language and technique on the internet for free. Developers make documentation and tutorials in many computer languages freely available.
The basics – getting started without prior knowledge
Computer programs are like cooking recipes.
Steffen’s explanation
Input: Raw, unpeeled potatoes
- Peel potatoes
- Fill up with water
- Add salt
- Switch on hotplate 4
Output: Cooked potatoes
You are the cookbook author (programmer) and tell your assistant (computer) what to do and when, so that the result is correct in the end.
You explain the process to your assistant (computer) via fixed cooking instructions (computer commands) so that a good dish comes out.
The stupid assistant (computer) works through your instructions meticulously. If you forget to write in your recipe that the assistant (computer) should switch on hot plate 4 (command), you will be punished later with raw potatoes (bug).
As a cookbook author, you often provide the guest with different alternatives. Either the guest prefers the potatoes as fried or boiled. The guest says which variant he prefers (input). Your recipe needs branching:
Input: Cooking method: fry
- Peel potatoes
- If: fry –>
- Cut into slices
- Oil in the pot
- If: do not fry –>
- Fill up with water
- Add salt
- Switch on hotplate 4
Output: boiled potatoes or fried potatoes
If you want to eat more than one potato, write in your cooking recipe e.g. Please skip to step 1 (grinding):
- Peel potatoes
- If: fry –>
- Cut into slices
- Put oil in the pot
- If: do not fry –>
- Fill up with water
- Add salt
- Skip to step 1 until potato count = 5
- Switch on hotplate 4
Output: boiled potatoes or fried potatoes
The potato count represents a variable for the computer. A variable is a memory location that can contain numbers, texts, groups of numbers and texts (arrays). When you call up the “potato count”, you get the value that is stored. You can overwrite or delete the value.
Now we have everything together. The computer ..
- … processes commands one after the other
- … accepts inputs, processes them and outputs them
- … remembers values with variables
- … and can be controlled with branches and loops
Learn programming in 10 steps
For you, I have put together 10 steps on how to go from a beginner (with no prior knowledge) to a geek.
#1 Soak up motivation
Before you start hacking away wildly at your keyboard, you need a good dose of motivation for programming.
Here are the TOP 6 benefits of learning to program:
- Get rich: Margins of 40% to 70% are realistic in software development. You develop software once and the free copies sell million times in the best case.
- Creative hobby for your free time: Get artistic with the tools, like with wood DIY projects. Develop your own features and the user interfaces of tomorrow.
- High salaries in the IT industry: As a software engineer, even career changers or those with a secondary school-leaving certificate earn a very good salary. The top salaries for experts are 250,000+ euros annual gross without any personnel responsibility (with enough skill).
- Develop apps according to your needs: Don’t like something about your favourite app? Change the app if it is open source.
- Solve computer errors more quickly: Instead of despairing when your computer goes haywire, you can find the solution to your problem quickly and in a structured way.
- Independence from geeks: The Telekom technician doesn’t come. Apple support doesn’t answer. Your laptop keeps hanging up. With your new skills, you are more independent of computer geeks who know how to use computers.
Programming, like any activity, has a light and dark side. Errors that you can’t solve immediately are not always pleasant. If you mistype or make a logic error in your software, the computer will display an error message.
Many beginners throw in the towel after 10 minutes and claim:
“Have no talent for this.” – “I don’t understand this maths stuff.” – “I’m just too stupid.”
The impatient beginner
Motivate yourself and pick a motivational asset from the top of the list. Ask others for help if you get stuck (forums, StackOverflow). Don’t give up after 30 minutes. Look at the instructions again and compare them with your code!
Experienced coders stare at their code for 60 minutes on many days, only to notice that they have forgotten a semicolon (beginner’s mistake). This is human, normal and part of coding.
Reality speaks
#2 Writing your first Hello World
Traditionally, the introductory project to coding in any language is called “Hello World”. You try to make a “Hello World” appear on your screen when you run your software.
If the computer displays a “Hello World”, you can already install the tools and know the structure of how a software is built. Installing the environment is often more difficult than actually coding the Hello World project. For beginners, I have compiled many step-by-step installation guides for popular languages and frameworks.
- TypeScript (JavaScript only better)
- Java
- Python
#3 Writing according to instructions
You want to code more than “Hello World”?
More features! More buttons! More outputs!
To build the features you want, you need to understand the basics and data structures of programming. You don’t have to make everything up as you go along. I have written basic tutorials for you, with which you can build useful applications.
e.g.
- Android Apps and Apple iOS Apps with Ionic
- Learn Java for beginners
- Learn PHP Laravel for beginners
- JavaScript / TypeScript for beginners
#4 Learning to read documentation
After you have a rough understanding of the basics of a language, you should read the documentation of the language when you need it.
Every language and framework should provide technical documentation with running text comments. This information comes first-hand from the developers and is the most up-to-date. Many documentations use versioning for the releases of the language or framework. In turn, many documentations are difficult to understand.
If you google for a coding question, 80% of the time you end up on Stack Overflow. Stack Overflow is a platform where inexperienced people can ask questions and (hopefully) the pros will answer.
Keep in mind with Stack Overflow: Many answerers …
- … only shine with half-knowledge
- … write inefficient code
- … don’t update their answers as the coding changes
A quick copy-paste from a stack overflow solution works in most cases, but …
- You don’t understand what the code does
- You don’t know the context
- The naming is often horrible (see Clean Code)
Use Stack Overflow. But keep my warnings in mind.
Steffen Lippke
#5 Writing Clean Code
What is clean code? Clean code? Yes, that’s right.
You should get into the habit of producing high quality code with your first line of code:
- Name the files, variables and functions with meaningful names.
- You call similar things similar and different things different.
- Write short and many functions
- Keep it stupid, simple: The simpler and shorter the code, the better the quality (except for naming variables and functions).
Why should I make the effort for clean code?
Other people want to read your code. If you name the variables with x, y, z, k or n, it will take much longer until another person understands the code (or you in 6 months). If you name the text field variable for the account number txtfieldAccountNumber
, the other colleague will find his way around more quickly.
Reading tip: My Clean Code Guides with many practical examples
#6 Working together in a team
If you can code alone, you have reached level 5.
The next challenge is to develop software in a team. A team consists of several coders who have different levels of knowledge
- Level of knowledge
- Education
- Background
- and preferences
You have to set up rules for the clean code, think about the structure of the project and architecture. A distribution of tasks according to strengths is part of it.
Every team goes through phases of discord. The software reveals many unexpected errors that colleagues blame on each other.
Versioning (e.g. Git) takes over the merging of the code. The software compares your changes to the code with the changes of others and merges them into one project.
Digital tools like Todoist, Trello or Jira are used by many teams to organize themselves. The documentation of the project is done in the codebase, which software later extracts (swagger).
#7 Learn advanced techniques
When you code in a team, you quickly learn new techniques. Other professionals will recommend tricks and tips that will help you progress.
A so-called “code review” is worth its weight in gold for beginners. Other experienced super pros go through your code with you in a meeting. They look for bad code, structures and (hopefully) give you constructive criticism and suggestions for improving the code.
I cover advanced topics on this blog:
#8 Self-promotion and coding effectiveness
The best coder never stands out as the best coder if they don’t market their services. I don’t mean you should shout around like a barker, but draw attention to your work well done in your meetings, presentations and code reviews.
Note: Don’t try to code the most lines of code or do to-dos, but create high coding effectiveness.
- Efficient – doing one thing well, e.g. concentrating on finishing a feature quickly.
- Effective – doing the right things, e.g. thinking about what feature the client really needs and implementing it.
Identify and address the core challenges of the project. Pick out the key building blocks of the product and do them well!
Example task list: The app should reliably synchronize tasks between devices. A bad developer builds the features like dark mode and internationalization first. A good developer builds the synchronization algorithm first and makes sure that the app never deletes a to-do too early.
#9 Putting new technologies into practice
The media practices’ buzzword bingo when it comes to software and Silicon Valley:
The highly-touted technologies that are supposed to change the world work, only most coders don’t apply them. University is where young coders learn about the latest technologies.
“Can I programme a blockchain for our supply chain reliability?”
Freshly graduated colleague
“Good idea. Put it at the bottom of the todo list (and forget about it right away)”
Boss (45 years old, two whining children)
Many companies don’t want to spend time and money on “unknown” technologies because they often involve a high initial investment with little output.
Try to privately incorporate the technologies into your projects, understand them, test them and play with them. The private project is a good argument that helps you to convince your boss.
#10 Create novelty and make it usable
If you have been able to use the latest technologies in practice, think about how to implement novel implementations. Use the latest abstract concepts and problems in mathematics, physics or science to solve them with code.
Go new ways. Test out and share your idea as an open source project.
Other beginner questions
How long does it take to write an app?
Short answer: You can create a simple example software or app in 10 to 40 minutes without prior knowledge.
Steffen Lippke
For a simple calculator app, a beginner needs on average 1 – 2 hours (with guidance).
The time it takes to complete your app depends on the ..
- chosen language
- The time it takes to install the environment
- Your requirements for the app
- Function – What features should the app have?
- Stability – What happens if a fool uses the app?
- Appearance – 0815 modular design or creative game?
- Number of coding errors
Which is better? Mac vs Windows?
Is Mac, Windows or Linux better for coding? This question is discussed very subjectively by many professionals and amateurs. In my eyes, it is a question of faith and not an objective comparison.
My answer: it doesn’t matter!
You can code with all operating systems. I have worked with all of them for a while and have tested them all. With all operating systems, you can develop all software equally fast and equally complex, e.g. Java, Python or PHP.
My tip: Use the operating system you like or which you use most of the time.
Steffen Lippke
Which language do I have to learn to do X?
Many beginners ask what they need to learn to code X, here is the resolution:
I want to code a .. | You learn to .. | with the following software .. |
Android App / Game | Kotlin / Java | Android Studio |
iPhone App / iPad App / Game | Swift / Objective-C | XCode |
Windows Tool | C / C++ / .NET | VS Codium |
Website | HTML, CSS, JavaScript | Visual Studio Code |
Game for XBox / PlayStation / Computer | C | Gamestudio |
Apps for Apple and Android | Ionic | VS Codium |
Databases | SQL | phpMyAdmin, postgress |
Artificial Intelligence | Python / R / TensorFlow | Jupiter Notebooks |
.. |
If you tend to want to earn more after learning a language, learn ..
- Cobolt – for insurance companies and banks
- Python with numpy – machine learning etc.
- GOlang – for hackers at Google (developed by Google)
- ABAP – business applications in SAP