Input and output (Edexcel GCSE Computer Science): Flashcards

📚Flashcards
Input and output in programming
Sign up to keep revising.Create a free account to study more flashcards and track your progress.

Practise the cards

13 cards from this deck

Show

What data type does input() always return?

A string (text)

Input in programming

Getting information from users

Output in programming

Showing results back to users

int() function purpose

Converts string to whole number

float() function purpose

Converts string to decimal number

print() function purpose

Displays output on screen

str() function purpose

Converts numbers to text

String concatenation

Joining text together

.format() method purpose

Creates customised output with precise spacing & alignment

< symbol in formatting

Aligns text to the left

symbol in formatting

Aligns text to the right

^ symbol in formatting

Centres text

{:>5.2f} format meaning

2 decimal places, 5 chars wide, right-aligned

Join 100,000+ GCSE students studying Flashcards with us.

Select your subjects, and get access to A+ resources today.