CHAPTER 1 (BINARY DENERY HEXA, COMPRESSION ...) Flashcards
(34 cards)
hexadecimal (IF YOU DONT UNDERSTAND THIS DONT WORRIE THIS INFO WILL JUST BE GOOD TO MAKE THE EXAMINER THINK YOUR SMART YOU DONT NEEDA NEEDA KNOW THIS BUT THIS WILL GET YOU AN A*)
state the number base and number of values or other shit
a base-16 number system
uses values from 0-9 and charecters from A-F
to symbalize data
F E D C B A 9 8 7 6 5 4 3 2 1 0
Binary (IF YOU DONT UNDERSTAND THIS DONT WORRIE THIS INFO WILL JUST BE GOOD TO MAKE THE EXAMINER THINK YOUR SMART YOU DONT NEEDA NEEDA KNOW THIS BUT THIS WILL GET YOU AN A*)
?
what base system and and the number of values
base -2 system
2 values DUH dumbass base-2 means it can repersent through 3 numbers
1 and 0’s
what does a base system/number mean in cs
in data repersentation
the number of values in a data representation type that can be used
Denary? (IF YOU DONT UNDERSTAND THIS DONT WORRIE THIS INFO WILL JUST BE GOOD TO MAKE THE EXAMINER THINK YOUR SMART YOU DONT NEEDA NEEDA KNOW THIS BUT THIS WILL GET YOU AN A*)
base system? AND VALUES
base -10
values 0-9
TF a bit? like 4 bit binary
a bit his a number of 1 or 0
like when they say a 8 bit binary number
it means there are 8 values like
4 4 = 8
0101 0010
converting a binary number to a denery (QUESTION HERE AWNSER IT THEN FLIP THE FLASH CARD)
BINARY= 1010
AWNSER
BINARY= 1010 DENARY=10
how? here ill explain
when you get a binary number to convert to denary alway and always js write the number done on a paper
1010
next make a table we know that the values of a binary number in denary multiply but 2 right so above the binary number write this
8,4,2,1
1,0,1,0 and where ever the 1 over laps the number count it like in this case 8 and 2… now add the two number for the denary = 10
WHAT IF ITS MORE THAN 4 BIT LIKE 8?
then keep multiplying by 2
64,32,16,8,4,2,1 (the paper will be non calc so try to learn this)
convert the denary number to binary
denary = 13
AWNSER
denary= 13
binary= 1101
(look at flash card 6 if you dont understand how to do this or js message me ill teach you)
hexadecimal (DONT LEARN THIS I AM JS SHOWING YOU THE DENARY TO HEXA CONV)
denary: 0,1,2,3,4,5,6,7,8,9, 10,11,12,13,14,15
Hxadecimal: 0,1,2,3,4,5,6,7,8,9, A, B, C, D, E, F
Binary addition rules
1+0=1
1+1=10
1+1+1=11
LOGICAL LEFT BINARY SHIFT?!(always comes)
when you hear left shift JS know that that means the VALUE ON THE LEFT IS REMOVED
like this binary = 0010 1100
left shift by 1= (d)010 1100
(d)= means deleted dont write this in the exam this is refrence
NOW since one value on the left has been removed logicaly all the values will move to the left to fill in the gap LEFT so
left shift by 1 = (d)010 1100
logical move= 0101 100(d)
now we are missing on value on the RIGHT WHICH WILL ALWAYS BE REPLACE BY 0 (NO MATTER IF THE VALUE THAT WAS REMOVED WAS A 1 OR A 0)
so IT WILL THEN = 0101 1000
(before = 0010 1100)
logical RIGHT SHIFT?(always comes)
when you hear right shift JS know that that means the VALUE ON THE RIGHT IS REMOVED
like this binary = 0010 1100
RIGHT shift by 1= 0010 110(d)
(d)= means deleted dont write this in the exam this is refrence
NOW since one value on the RIGHT has been removed logicaly all the values will move to the RIGHT to fill in the gap right so
RIGHT shift by 1 = 0010 110(d)
logical move= (d)001 0110
now we are missing on value on the LEFT WHICH WILL ALWAYS BE REPLACE BY 0 (NO MATTER IF THE VALUE THAT WAS REMOVED WAS A 1 OR A 0)
so IT WILL THEN = 0001 0110
(before = 0010 1100)
what happens to the value after RIGHT SHIFT
eg the dinary num 44 gets devided to 22
SO THE NUMBER IS DEVIDED IN HALF
negitive binary / 2’S COMPLEMENT
35 DENARY TO -35 DENARY?
CONVERT 35 TO BINARY
0010 0011
NEXT STEP INVERT THE NUMBERS (1=0 AND 0=1)
1101 1100
NOW JS ADD 1 TO IT BUT REMEMBER THE ADDITION RULES (1+1=10 1+0 = 1 and 1+1+1=11)
SO
1101 1100
+ 1
———–
1101 1101 = -35
negitive binary / 2’S COMPLEMENT
-35 DENARY TO 35 DENARY?
-35 denary = 1101 1101
first INVERT THE NUMBERS
1101 1101= 0010 0010
AND FINNALY ADD 1
0010 0010
+ 1
———-
0010 0011 = 35 that easy
charecter sets?
a type of spread sheet in a computer
where each charector is repersented by a binary number
EXAMPLE
A =1011 (MAKING THIS UP)
name the two main type of charecter sets?
ASCII AND UNICODE
ASCII?
repersents through an 8-BIT binary
256 charecters
not alot from many language
UNICODE?
16-bit binary number
larger bit = more charectors
65,000 CHARECTORS
can be used for emojies symbols etc…
pixels
a small dot of colours that is displayed with many others to create an image
resolution
the dimensions of an image
metadata?
additional data that is stored in the image
LIKE DIMENSIONS, TIME AND DATE the image was taken
colours depth
the number of bit that are used to create each colour in an image
sound sampling
a little piece of sound that is rocorded at regular time intervals
sample rate
the number of sample recorded each ecound