Project

Coffee Machine (JavaScript)

Challenging
1313 completions
~ 6 hours
4.5

This project allows you to get a taste of JavaScript. Practice working with functions, challenge yourself with loops and conditions, and get more experience with JS.

Provided by

JetBrains Academy JetBrains Academy

About

What can be better than a cup of coffee during a break? Two cups. Press a couple of buttons on the machine, and, voilà, a burst of raw energy is in your hands. But first, we should teach the machine how to do it. In this project, you will work on a coffee machine simulator. This machine uses regular ingredients — coffee, milk, and plastic cups. Should it run out of something, it will show you a notification. Our device will serve espresso, cappuccino, and latte. And since nothing is for free, it will also charge coffee lovers for a cup.

Graduate project icon

Graduate project

This project covers the core topics of the Introduction to JavaScript course, making it sufficiently challenging to be a proud addition to your portfolio.

At least one graduate project is required to complete the course.

What you'll learn

Once you choose a project, we'll provide you with a study plan that includes all the necessary topics from your course to get it built. Here’s what awaits you:
Write a program that puts some basic information on the screen. Let the machine describe what it takes to make a cup of coffee!
The machine should calculate how many ingredients it needs to make the required amount of coffee.
Program the machine to calculate how many cups it can make based on the number of set ingredients.
Teach your virtual coffee machine to perform three basic actions: collect the money, replenish the supplies, and serve the coffee.
Program the machine to display how many supplies it has on the screen. Work on the main loop: now, the menu keeps updating until users choose to exit.
Enhance your coffee machine with any new functionality you wish to add.

Reviews

Juan Esteban Serrano Aldana
4 months ago
I love the final stage—it really fosters creativity and builds confidence in developing truly functional solutions. The third stage builds on the progress made in the second; overall, you go over practically the entire curriculum. Thank you for this excellent project!
Lars Roesicke avatar
Lars Roesicke
6 months ago
I became more familiar with basic JavaScript language features, such as switch cases, loops, templating, and functions in general. I also wrote my first complex objects and used a list. For a starter project, this was quite satisfying.
Francesco Cara
7 months ago
For this project I used loops, switches, string interpolation and inputs.

4.5

Learners who completed this project within the Introduction to JavaScript course rated it as follows:
Usefulness
4.6
Fun
4.4
Clarity
4.6