← 3.3 Identifiers and Operators

Type conversion before arithmetic

Computer Studies · Grade 10 · about 40 minutes

input() is text. int() and float() turn it into a number. str() turns a number into text. Forgetting this joins "50" and "20" into 5020.

Sign in to read this lesson

Lessons are for learners and teachers with an account. Browsing the curriculum — subjects, strands and what each sub-strand covers — stays open to everyone.

  • 8 sections of explanation, worked examples and diagrams
  • 1 practice task with hints and worked answers
  • A quiz that marks itself as you go
  • Your progress kept across every subject you take
Sign in Create an account