Convert algorithms 2 (Edexcel GCSE Computer Science): Flashcards

📚Flashcards
Convert algorithms 2
Sign up to keep revising.Create a free account to study more flashcards and track your progress.

Practise the cards

12 cards from this deck

Show

What do selection statements do in Python?

Test conditions & execute different code based on true/false

Python keywords for selection statements

if, elif, and else

Diamond shape in flowchart represents

A decision point where program makes a choice

When to use else in flowchart conversion

When flowchart has code/processes on the 'no' path

When to use elif statement

When flowchart has multiple selection symbols in sequence

First decision symbol converts to

An if statement in Python

Second decision symbol converts to

An elif statement in Python

What else statement handles

All other cases not covered by if/elif

Multiple diamond shapes usually require

elif statements in Python code

elif vs separate if statements

elif for mutually exclusive conditions, if for independent

Common mistake with 'no' path

Not handling it with appropriate else statements

Common mistake with input data

Missing conversion to correct data type like int()

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

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