Strings in JavaScript (OCR A-Level Computer Science): Flashcards

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

Practise the cards

9 cards from this deck

Show

What are strings in JavaScript?

Sequences of characters used for text

String property for length

.length

Three common string methods

.substring(), .toUpperCase(), .toLowerCase()

.toUpperCase() purpose

Converts string to uppercase

.toLowerCase() purpose

Converts string to lowercase

'JavaScript'.length output

10

'JavaScript'.toUpperCase() result

'JAVASCRIPT'

Common string comparison mistake

Using == instead of ===

Correct operator for strict equality

===

Explore OCR A-Level Computer Science Revision Notes by Topics

Explore OCR A-Level Computer Science Model Answers by Topics

Explore OCR A-Level Computer Science Quizzes by Topics

Explore OCR A-Level Computer Science Exam Questions by Topics

Join 100,000+ A-Level students studying Flashcards with us.

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