Sign In

Communications of the ACM


Block-based Programming in Computer Science Education

block-based programming concept, illustration

Credit: Getty Images

Block-based programming is increasingly the way that learners are being introduced to the practice of programming and the field of computer science more broadly. Led by the success of environments like Scratch (see the figure appearing later in this column) and initiatives like's Hour of Code, block-based programming is now an established part of the computer science education landscape. While not a recent innovation (for example, LogoBlocks has been around since the mid-1990s), the last decade has seen a blossoming of new toys, games, programming environments, and curricula that incorporate block-based programming features. Given this growing presence, it is important that we as a community look critically at the block-based programming modality to understand its affordances, drawbacks, and identify how best to use it as a means to welcome people into the discipline of computer science and support them as they grow and learn.

Back to Top

What Is Block-based Programming?

Block-based programming has a number of key features that make it distinct from conventional text-based programming and other visual programming approaches. Block-based programming uses a programming-primitive-as-puzzle-piece metaphor as a means of providing visual cues to the user as to how and where commands may be used. Figure 1b shows a block-based program written in Scratch. Block-based programming environments have been designed for children as young as five years old but most environments are designed for kids ages eight to 16. Writing a program in a block-based environment takes the form of dragging-and-dropping programming instructions together. If two instructions cannot be joined to produce a valid statement, then the environment prevents them from snapping together. In this way, block-based programming environments can prevent syntax errors while still retaining the practice of authoring programs by assembling statements one-by-one.


No entries found

Log in to Read the Full Article

Sign In

Sign in using your ACM Web Account username and password to access premium content if you are an ACM member, Communications subscriber or Digital Library subscriber.

Need Access?

Please select one of the options below for access to premium content and features.

Create a Web Account

If you are already an ACM member, Communications subscriber, or Digital Library subscriber, please set up a web account to access premium content on this site.

Join the ACM

Become a member to take full advantage of ACM's outstanding computing information resources, networking opportunities, and other benefits.

Subscribe to Communications of the ACM Magazine

Get full access to 50+ years of CACM content and receive the print version of the magazine monthly.

Purchase the Article

Non-members can purchase this article or a copy of the magazine in which it appears.