You are on page 1of 4

Get started learning Python with DataCamp's free Intro to Python tutorial.

Learn Data
Science by completing interactive coding challenges and watching videos by expert
instructors. Start Now!

Ready to take the test? Head onto LearnX and get your Python Certification!

Functions

What are Functions?

Functions are a convenient way to divide your code into useful blocks, allowing us to order
our code, make it more readable, reuse it and save some time. Also functions are a key way
to define interfaces so programmers can share their code.

How do you write functions in Python?

As we have seen on previous tutorials, Python makes use of blocks.

A block is a area of code of written in the format of:

You might also like