OOP Crash Course - FreeCodeCamp Flashcards
1
Q
What are primitive data types?
A
Variables that store single, simple values.
2
Q
What are some examples of primitive data types?
A
Byte, int, float, Boolean, double, char
3
Q
What is the difference between a structure and an array?
A
A structure can store different types of data. An array will only allow you store int and strings.
4
Q
What is the main issue with structures?
A
You can’t define functions within one
5
Q
What are objects?
A
Objects are instances of a class
6
Q
What is a class?
A
It is a template for an object