Revise Computing
Revision notesQuestionsFor schools
Log inStart revising free
Revision notesQuestionsFor schoolsLog in
GCSE Computer Science/Supplementary programming practice/Output and Sequence

Basic print / output

301.1 Output and Sequence

Practise exam questions

Output and Sequence — Note 1 of 3

Use print statements to display text or data.

What you need to know

The print() function is the most fundamental way to produce output in Python. It sends text, numbers, or the value of variables to the console so the user can see results. Every program that communicates with a user will use output.

What to know

  • print() outputs text to the console
  • Strings must be wrapped in quotes (single or double)
  • Multiple items can be separated with commas
  • print() adds a newline at the end by default
  • Use end='' to prevent the automatic newline

Code examples

Printing a simple string
python
print("Hello, world!")
# Output: Hello, world!
Printing multiple values
python
name = "Alice"
age = 15
print("Name:", name, "Age:", age)
# Output: Name: Alice Age: 15
Next note →Literals vs variables301.1 Output and Sequence

Back to Output and Sequence

Specification notes for programming are in Paper 2.

Output and Sequence

Note 1 of 3

  1. 1Basic print / output
  2. 2Literals vs variables
  3. 3Sequence execution
Topic overview

© 2026 Revise Computing · revisecomputing.co.uk

Privacy noticeTermsContact

Revise Computing is an independent revision resource. It is not affiliated with, or endorsed by, OCR (Oxford Cambridge and RSA Examinations).