Input and output (Edexcel GCSE Computer Science): Quizzes

📚Quizzes
Input and output in programming
Sign up to keep practising.Create a free account to play more quizzes and track your progress.

Practise the questions

12 questions from this quiz

Show

What data type does the input() function always return in Python?

String (text)

If a user types 42 into an input() function, how is it received by the program?

As the text "42"

Which function converts string input to a whole number?

int()

Which function converts string input to a decimal number?

float()

Why must you convert input data from the input() function?

Input is always text; convert for calculations

What is the purpose of the print() function?

Display output to user's screen

What happens when you use print() with multiple values separated by commas?

Spaces are created between values

What is string concatenation?

Joining text together

What does the .format() method allow you to do?

Create output with spacing control

In string formatting, what does the < symbol do?

Aligns text to the left

In string formatting, what does the > symbol do?

Aligns text to the right

What does the format {:>5.2f} do in Python?

Right-align, 5 chars wide, 2 decimals

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

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