Definitions Flashcards

1
Q

ENCAPSULATION

A

> Process of combining data members and functions in a single unit called class.
Prevent the access to the data directly.
Access to member function is provided through the functions of the class.
Helps with data hiding.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

char

A

Size = 1 byte (8 bits)
2^{8} = 256
One ASCII character
EX: ‘f’

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

unsigned int

A

Size = 4 bytes (32 bits)
2^{32}
Binary int
*Positive numbers only

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

float

A

Size = 4 bytes (32 bits)
2^{32}
Floating point number
EX: 3.141592

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

double

A

Size = 8 bytes (64 bits)
2^{64}
Floating point number
EX: 3.141592653589793

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

signed int

A
Size = 4 bytes (32 bits)
2^{32}
Binary int
*Half positive / half negative numbers 
** Using two's compliment to negate number
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Calculate a simple two’s compliment

A
  • Flip bits
  • Add 1
    Ex: 5 (0101)
    Flip: 1010
    Add 1: 1011
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

%c

A

Single Character
Bytes = 1
Char / Signed Char = -128 - 127
Unsigned Char = 0 - 255

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

%d

A

decimal integer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

%u

A

unsigned decimal integer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

%o

A

octal

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

%x

A

unsigned hexidecimal number

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

%f

A

decimal floating point

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

%e

A

scientific notation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

%s

A

string

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

%%

A

prints % symbol

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

%f
%.nf
%mf
%m.nf

A
%f = default: show 6 decimal places
%.nf = Show nth decimal places
%mf = prints with minimum width m
%m.nf = n decimal places & minimum width m
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Front End Development

A

Build code for user interaction

EX: GUI, Phone APPS

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Back End Development

A

Code that works behind the scenes away from user interfacing. Low level progamming.
EX: Device drivers, complex algorithims

20
Q

Middleware

A

SW that bridges the low level and user high level SW

EX: Send BT CAN data to the GUI or APP

21
Q

Type Promotion

A

When the two operands have different types, the compiler attempts to add a type conversion to make the types the same.

22
Q

Casting

A

Occasions when you or the compiler may have to temporarily treat the variable as though it were of another type.

23
Q

Overflow

A

An operation results in a number that is too large to be represented by the result type of the operation.

24
Q

Underflow

A

An operation results in a number that is too small to be represented by the result type of the operation.

25
Q

Abstraction

A

Display only essential information and hiding the details.

26
Q

Const

A

Value does not change for the life of the program

27
Q

Prefix / Postfix opperators

A

++a / a++

–b / b–

28
Q

Pointer referencing

A

Look up the ADDRESS of the variable location

29
Q

Pointer de-referncing

A

Get the variable data IN the address of the variable location

30
Q

Definition

A

The statement(s) of the task the function performs when called.

31
Q

Declaration

A

Statement of how the function is to be called

32
Q

Layout of a function

A

retVariableType functionName(parameter1, …
parameter2, …
,parameterN)
{
statement(s);
}

33
Q

Function Declaration

A

returnVariableType functionName(parameter1, …
parameter2, …
parameterN);

34
Q

Mutators

A

Functions that access and/or modify data values in classes

35
Q

Methods

A

Functions in classes

36
Q

Constructor

A

Special class functions which performs initialization of every object. The Compiler calls the Constructor whenever an object is created. Constructors initialize values to object members after storage is allocated to the object.

37
Q

Destructor

A
Destroy the class object.  
Important tasks of a destructor is releasing memory that was allocated by the class constructor and member functions.
38
Q

Pointer

A

Variable which holds the address of another variable of same data type.
> Used to access memory and manipulate the address

39
Q

Pointer: &

A

Check this memory address
EX:
int var;
&var - gives the memory address for the variable.

40
Q

Pointer Variable

A

Variable which holds an address of some other variable

41
Q

Pointer Initilization

A

Assigning address of a variable to a pointer variable

42
Q

Pointer Dereferecing

A

Access the value of the variable

43
Q

Double Pointer

A

Pointer to store the address of another pointer

44
Q

This

A

Pointer that returns its own address

45
Q

Mutators

A

Functions that access and/or modify data values in classes.