Foundations Flashcards

(11 cards)

1
Q

What is fermats little theorem

A

a^p = a mod p

a^(p-1) = 1 mod p

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

What is the public key pair for RSA

And what are they

A

(n, e)

n=pq

e is between 0 and (p-1)(q-1)
It is coprime of (p-1)(q-1)

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

What is the private key for RSA

A

d

de = 1 mod (p-1)(q-1)

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

How do you encrypt a message M

A

Encrypted message = M^e mod n

n is larger than M

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

How do you decrypt a message c

A

M = c^d mod n

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

What’s the difference between combinations and permutations

A

Permutations care about the order of the set, combinations don’t

Think of it like a permutation padlock

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

What is the equation for possible combinations of K numbers into a set size N if the order matters
(permutation)

A

n! / (n - k)!

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

What is the equation for picking a set of size n from k values when the order doesn’t matter
(combination)

A

n! / k!(n - k)!

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

How do you find the expected value of a random variable

A

For P(X=x)

Sun all the x(probability of x)

E.g 0(0.3) +1(0.25)+2(0.03) etc

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

What is the variance of a random variable

A

Var(x) = e(x2) - e(x)2

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

How do you find standard deviation of a random variable

A

Root(var(x))

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