Complete x86 Assembly Programming | 120+ Practical Exercises | Hou Sam | Skillshare

Complete x86 Assembly Programming | 120+ Practical Exercises

Hou Sam

Play Speed
  • 0.5x
  • 1x (Normal)
  • 1.25x
  • 1.5x
  • 2x
137 Lessons (9h 29m) View My Notes
    • 1. 01-Introduction to the programming languages

      2:04
    • 2. 02-Introduction to the Assembly language

      2:26
    • 3. 03-Introduction to the computer's architecture

      1:48
    • 4. 04-The internal architecture of the 8086 processor

      2:37
    • 5. 05-Simulation of the main memory

      1:50
    • 6. 06-How to install emu8086

      4:35
    • 7. 07-First step

      3:23
    • 8. 08-How and where define variables

      5:21
    • 9. 09-The rules of naming a variable

      1:32
    • 10. 10-Size directives

      1:34
    • 11. 11-The Constants

      2:36
    • 12. 12-Types of the numerical values

      4:45
    • 13. 13-Data registers

      1:23
    • 14. 14-Mov instruction

      6:37
    • 15. 15-Mov instruction example I

      9:21
    • 16. 16-Mov instruction example II

      4:50
    • 17. 17-Xchg instruction

      2:34
    • 18. 18-ADD & SUB instructions

      3:48
    • 19. 19-ADD & SUB instructions example

      5:33
    • 20. 20-INC DEC NEG instructions

      3:56
    • 21. 21-INC DEC NEG instructions example

      5:33
    • 22. 22-From binary to hexadecimal

      4:05
    • 23. 23-The difference between the signed and unsigned numbers

      5:30
    • 24. 24-How to choose the right size for a number

      2:34
    • 25. 25-The Flags register

      3:20
    • 26. 26-The overflow

      4:07
    • 27. 27-The overflow in NEG instruction

      2:21
    • 28. 28-SF ZF

      2:43
    • 29. 29-SF ZF example

      3:50
    • 30. 30-PF

      4:01
    • 31. 31-Introduction to the branching

      4:46
    • 32. 32-The branching -Part I

      5:40
    • 33. 33-The branching -Part II

      2:02
    • 34. 34-Branching example -overflow 1

      3:28
    • 35. 35-Branching example -overflow 2

      2:11
    • 36. 36-Branching example -comparing numbers

      4:21
    • 37. 37-The branching -Part III (1)

      3:26
    • 38. 38-The branching instructions in the unsigned numbers -example

      5:51
    • 39. 39-The branching -Part III (2)

      3:05
    • 40. 40-The branching instructions in the signed numbers -example

      2:40
    • 41. 41-Using the branching instructions with PF -example

      3:27
    • 42. 42-Data types: chars

      6:50
    • 43. 43-How to print a char in the DOS screen

      2:21
    • 44. 44-How to read a char from the keyboard

      1:57
    • 45. 45-The DOS services -example

      1:49
    • 46. 46-Operations on the chars

      4:05
    • 47. 47-From the uppercase to the lowercase

      3:54
    • 48. 48-Read a digit -example

      2:57
    • 49. 49-How to print a message in the DOS screen

      4:31
    • 50. 50-From the lowercase to the uppercase

      4:22
    • 51. 51-Simple IF

      4:18
    • 52. 52-Complex IF

      6:29
    • 53. 53-IF-Else Condition

      3:11
    • 54. 54-The repeat loop

      5:11
    • 55. 55-The while loop

      4:09
    • 56. 56-The For loop

      3:22
    • 57. 57-Segments registers

      3:57
    • 58. 58-The offset

      7:35
    • 59. 59-Memory models

      4:26
    • 60. 60-Segments registers -notes

      2:07
    • 61. 61-Introduction to arrays

      3:51
    • 62. 62-How to define an array

      4:05
    • 63. 63-The Sum of an array

      11:26
    • 64. 64-Read & write in arrays

      5:34
    • 65. 65-Max value in an array

      4:02
    • 66. 66-Looking for a value in an array

      3:33
    • 67. 67-Min value in an array

      5:12
    • 68. 68-Addressing modes I

      4:03
    • 69. 69-Addressing modes II

      7:58
    • 70. 70-Addressing modes -notes

      6:21
    • 71. 71-Counting the occurrence of the number 5 in an array

      3:38
    • 72. 72-Addressing modes III

      6:57
    • 73. 73-Arrays with tow dimensions

      2:43
    • 74. 74-How to index an array with tow dimensions

      3:56
    • 75. 75-Max value in an array with tow dimensions

      3:04
    • 76. 76-The sum of the third column

      8:43
    • 77. 77-AND

      2:29
    • 78. 78-OR XOR

      6:10
    • 79. 79-How to know if a number is even

      3:27
    • 80. 80-The masks

      6:29
    • 81. 81-NEG instruction simulation

      5:10
    • 82. 82-Converting between the uppercase & lowercase

      3:46
    • 83. 83-TEST instruction

      5:01
    • 84. 84-TEST instruction -examples

      4:02
    • 85. 85-Other examples

      2:30
    • 86. 86-NOT

      2:27
    • 87. 87-Shift left

      5:13
    • 88. 88-Using shift left in the multiplication

      3:49
    • 89. 89-How to count the number of 1 using SHL instruction

      2:35
    • 90. 90-Shift right

      4:11
    • 91. 91-The difference between SHR and SAR

      1:33
    • 92. 92-ROL RCL

      4:33
    • 93. 93-Reverse the content

      2:54
    • 94. 94-How to count the number of 1 using ROL instruction

      2:29
    • 95. 95-ROR RCR

      1:51
    • 96. 96-From binary to decimal 1

      1:34
    • 97. 97-From binary to decimal 2

      4:43
    • 98. 98-From binary to decimal 3

      2:34
    • 99. 99-From binary to decimal 4

      2:22
    • 100. 100-Stack

      6:58
    • 101. 101-XCHG instruction simulation

      3:26
    • 102. 102-Reverse the elements of an array

      4:41
    • 103. 103-Procedures

      4:18
    • 104. 104-CALL & RET instructions

      5:40
    • 105. 105-Procedures -examples

      4:24
    • 106. 106-Procedure: even or odd

      7:40
    • 107. 107-The parameters and the returned value

      7:53
    • 108. 108-Dealing with Stack -advanced ways

      7:57
    • 109. 109-The Macros

      4:46
    • 110. 110-Macros -example

      2:21
    • 111. 111-Libraries

      7:35
    • 112. 112-The emu8086.inc library

      6:19
    • 113. 113-The Loop Instructions

      5:20
    • 114. 114-MUL Instruction

      5:15
    • 115. 115-How the MUL instruction changes the state of the flags

      7:37
    • 116. 116-DIV instruction

      3:18
    • 117. 117-DIV instruction

      2:54
    • 118. 118-Input & Output a String

      4:37
    • 119. 119-MOVSB

      8:29
    • 120. 120-STOSB

      3:28
    • 121. 121-LODSB string

      3:23
    • 122. 122-SCASB string

      3:43
    • 123. 123-CMPSB

      5:43
    • 124. 124-DatePrint the date and time

      3:12
    • 125. 125-Other resources

      2:31
    • 126. 126-Introduction

      2:54
    • 127. 127-From decimal to binary

      4:03
    • 128. 128-From binary to decimal

      1:34
    • 129. 129-From decimal to hexadecimal

      2:41
    • 130. 130-From hexadecimal to decimal

      3:33
    • 131. 131-From binary to hexadecimal

      1:29
    • 132. 132-Represent unsigned numbers

      5:59
    • 133. 133-The Addition operation

      2:55
    • 134. 134-Represent signed numbers

      4:49
    • 135. 135-How to read numbers

      3:36
    • 136. 136-The subtraction & multiplication

      2:08
    • 137. 137-The characters representation

      3:36

About This Class

The most effective course to learn the X86 assembly language through focusing on the practical side and exercises in a funny way will make you learn quickly and easily, as well as a Udemy certificate that you can  add  to your CV with confidence.

In this course we will take you from zero to the professionalism acquiring the basic skills and principles of the language with the deep & right understanding.

  • Are You:

    1. An absolute beginner and you have no idea about programming.

    2. Beginner and you have a little programming experience.

    3. Expert and you have a long experience in programming.

    And you want to learn x86 assembly language?

                                             You're in the right place !!!

  • Are you interested in :

    1. Hardware Developing

    2. Software Developing

    3. Reversing Ingeneering

    4. Data Security

    5. Ethical Hacking

    6. Networking

    7. Operating Systems

    8. Debugging

    9. Other processor's Assembly Language

    10. Others

    11. Student in the University 

     And you want to learn Assembly Language either you want to be an expert in your specialty or for other reasons

                                               You are in the right place !!!

   Complete x86 Assembly Programming | 120+ Practical Exercises is the best course on udemy to learn x86 Assembly Language.

  • 136+ non-boring lectures ( 4 min avg time ): well explained, short, detailed, focus on the principals

Transcripts

1. 01-Introduction to the programming languages: hello over one. Welcome to our course off the assembly. Long wage off Intel 80 86. It is video. I want to make everything clear. What is the proclamation? Long wage with his the program and so on. So if you have a knowledge about the proclamation so you can actually avoid these video. So this video is for the beginners that has no knowledge about the program ation. What is the program? Mission Language. So it actually long wage alot you to make a programs. Nothing hard. No. What is the program? The program is set off. Guard it in that allow you to resolve a problem. What he's done guarded him. Let there, for example. But we have school and we need to calculate the great off students. And then we need to sort these. Great. So this is our problem now. We should make program that calculated the great off the students and then sort the student depending on the grades. Here, we need Teoh Al Gore ism. The first algorithm is for calculating the grades off the student and the 2nd 1 is to sort the students depending on the grades. What is the I guarded him, so it set all steps or instructions that we need to follow in order to solve apart off a problem. So the first part of the problem is to calculate the great the second parties to source the student. So what are the steps to calculate the grades off students? It easy. All we have to deal is to add the march off students and then divided by the number off the subject. The second, a guard to me, is to sort the student. And actually there is a lot of ways to do that. So I wish everything is clear. See you in the next lesson. 2. 02-Introduction to the Assembly language: but over one in this video, we will see an intra Duchin off the assembly language. So what is the assembly language? The assembly language is allowable language program mission. What is the program Ation language. Actually, in the previous video, we saw distribution about the program ation language. But the question is, what is the lower level language program ation. So there are two types of the program ation language. The high level program ation language on the lower level program nation language for the heart of all long wait program ation. It actually requires the Centex. So I should know the San tax. Which one is allowable? Which one is not allowable and so on, as requires the libraries and the factions. So actually they do many process. They make the work easier and shorter for the lower level proclamation. Language diversity is required of the sentence aswell. So the same thing with the heart of our program ation language as requires a knowledge off the Internet or architecture of the processor. So each processor has antimony architect er, so it requires knowledge off the Internet architecture all the processor, in order to make effective programs with no mistake, and we will see that in the next lesson. So everything is available. You don't have to worry about anything on a basic knowledge off the data representation, and we have all of those in the bonus. So the decimal, the finery and exit decimal how to convert between these systems? How do the operations on this systems, and so on? Why the answer? 80 86. So because there's a sample design, the designers office maker Processor did very example and easy design. And since you are a beginner in the assembly language, you'll have to start to the sample. Think so? You could not, for example, starts with the E 35 C seven, for example, because they're actually complicated and you're not understand anything. The other detainee's that the until 80 86 is compatible with the new versions. For example, the 8400 and 86 8300 and 86 8200 and 86 so on. So this is the yen. See you in the next video 3. 03-Introduction to the computer's architecture: Hello, everyone, and welcome to our course off the assembly language off the processor. 80 86. So in this lesson, we're going to talk about the general architecture off the computer. So the computer consists of the central processor unity as it known CPU, the memory and imports. Oslo's contractors like K Board, Preacher and External Storage taken example off the hard disk DVD. So in our course we had basically this part, the CPU and memory. And then we will talk about the ampoules and outward contra as well. But in this time of focus on the memory and the CPU, what is the relation between the CPU on the memory? So the main fall off the memory is stock? The informations that given by the CPU, how does it work here We define two operations reading and writing operation, starting with reading information. So when the CPU need to read in information from the memory, it sends a request. And also it said, the address off this information. So this is mean like I want to read the information that placed in this arduous and after a very short sign, the information will be available the next operation is the writing and this is the same thing. So it's ended up was to write an information plus the address where the information will be stopped on. This is the end off the lesson and see you in the next lesson. 4. 04-The internal architecture of the 8086 processor: hello over one or white home to this lesson in this lesson, we are going to see the internal architecture off the 80 86 maker processor. This maker processor is actually consists off two important units, which are the A l u and the registers. So the A l u and their registers the lur, the artist, music and logic unit is taking charge off the mathematic operations and the logic operations. The mathematic operations like the additions, the multiplication, the logical operations, for example, the end or explore and so on. Now we move to the registers. What is a register? So it's a unit in the memory that has 16 bits in the 16 bits we are able to save and stalk a data. So when the processor is executing a program that need unity in the memory in order to treat this program and actually that need the registers, so the registers is the unity in the memory that has 16 bit. This maker processor is actually contained 14 registers. There is the data registers, which are the a X bx C X and the D eggs. And there are pointer registers, which are the S B and B P. So the P is for the Poynter as they are, the index registers so as I and the I and I for the index. And then there are the segment registers art of the CS and DS as S and E. S. And as here for the segment. Also, there is the I B or the instruction pointer this register and tickets the next step off the program in the memory. And in the end, we have the flags. In this lesson. I don't ask from you to memorize all these registers. So we're just mentioning that these registers are available in the next lesson. We will explain them. We will see How can we use them? Where can you use them and when can we use them? So we will see all of that in our way off the professionalism. See you in the next lesson. 5. 05-Simulation of the main memory: hot over one. In this lesson, we will see the central memory. Or how can we imagine the central memory? The central memory is the metrics. Bob consists. Off COLUMNS INCH column is called bit So this is a column, and this is a column, and this is a column, and this is a column aswell on each of these columns. We can say a data in its that represented by zero or one. This metrics is haunted by a rows and columns, so rows and columns in our case here, the number off the columns is eight. The neighbor off the rose is not important. Each column called bits and each row called bites. That means that it's bit is it? Want one bite? So this is a bite, and this is a bite, and this is a part as well, and it's the one. The important thing in the memory is the address in vitro in the memory has own otherness. The first row has the ultra zero. The second row has the address. One. The third row has the address still and so on and since there is a lot off rose in the memory, so that's make the reading operation by the binder system hard and complicated. That's why it would be better to use the exact date more in order to read. This address is the last information. The last pit or the last column is the Alice B. On the first pitch on the left for the first column on the left is the MSB. So this is the end to you in the next lesson. 6. 06-How to install emu8086: Hello, guys. And welcome to our listen industries. And we're going Teoh, explain how to don't loot and install the simulator off a maker. Percy's here. 80 86 So personally roids and 60 miniature. I would like in the first link I would less this link. No. So be able to Don't know this. So it's easy. Just click on Don't know. So don't Don't know, did it? You go to open feel fire and then we struck the fire. You see, you go to the point, open it and click on set up. So here we don't lose normally, as we don't want any, we install it normally as reinstall any program and windows Glick witnessed all not hard thing. So if you this is a referee, don't worry, because ah is only about ah, it's only knew that this program is installed. Here we go looking to last the community around here ago. So this is it. The interface off name of 18 86? Yes, he that so Here we'll click on. So it's fish. This is the interface her We have new to open new project and it is open for opening like important that we have done before. And we have also emulates this would talk about it later in the next lesson. We have a calculator here. We can calculate our operations in the sea more or hex are oft or in finery. So it's how for house you see here and you see more. The result is eight. And if you could, for example, and binary, the results will be cause he's here. Also, you have ah contractor. So, uh, if we want to Cooper's from system to another exalt the Seymour. We're using lots in our problems. So, for example, we put five in Exxon and here we go. Or is it the result in binary and we can't judge Example 51 programmable. And there there are results in old systems. So yeah, this is very helpful itself. Help you when you're running the program. So this is it for our listen today we know how to don't know. Then install the 18 86 simulator. So see you in the next person. Thank you 7. 07-First step: hot over one. In this lesson, we will write our first code. So we will see the general form on the script for the maker processor 80 86. We open our emulator. So here we choose the first option. I don't clear that the first row were right. Name girl on and then the name of our program, for example, Test. So the name of a program is this after that? That model small. So that model small. We will see that in the next lessons when we were mastered the long which we will understand what is mortar and small and all of that. All you need to do now is remember that you have to ride thoughts, model small and then Dodd data in this part. So just after the data, we will define the variables and the constant For those who has no idea about that. We would explain them as well after that date a coat. So that's code. That means that just after that in this part we write the code. So we write our script aan ultra the code there is the main. So the entries scripts. It's called Men Prosecutors so made Brock. So here we write the steps on after the end off the entry scripts were right, main and be welcome. Is that the end off the entry script? Or and prosector? Actually, you don't have to worry about that because you will get used off these steps in our next lessons. Just focus on the general form off our scripts. And in the end of the program, rights and thought means the end of our program. Small reminder. In the first off our scripts we wrote name Golan and then the name of the program in our example here test or test one four, for example, at, for example, to number. So at the numbers. So just given name that indicate to function off this program and then more than small So after the name where I'd thought models more. After that, we're right data and in this part for those who knows the body boards and the constant. So here we defined them. After the valuables and the constant, we'll write code. Well, right, dotes goat. And here we write our scripts and here we have the process. Your main Prock hair arrived the steps and then may and then procedure on the lost in is and so that's all in our lesson. In the next lessons, we will see all the cases different script. So you will get used off the form of this program. So there is no worries. So you in the next lesson. 8. 08-How and where define variables: Hello, everyone, and welcome to our listen and this is it. We're going to look about the variables and the constant. So what are the variables and the constant? Personally, we talk about the variable. The variable is, ah, position that's reserved in the central memory that has two characteristics. The arteries and the size. So the address is the number of interest and central memory and the size. So how many rows it took in the central memory? For example, the variable that has the number 15 in the central memory is the address and has, ah one bite other side. So this is it means one row, another variable, but has the number 350 has, for example, the size off to bite and 16 beats. So it's just mean to rules. So the variable is a position that reserved in the central memory that has two characteristics the address and the size. So the question. What is the idea of the variable and where can we use it in the previous lessons? We way said that this persistent has 14 registers not to use Teoh stop. The information's off the program. So who's supposed that all these abusers are cubes. So this is means all the informations that are in these registers are needed. So we cannot be late. Ah, an information and odd. Another information, and then the same, please. So here we go to you, the central memory. And this is what we called the voluble. So when Russia program and we know that all the registers are cubes. So you go to the central memory. We define a variable and we different also the address and the size. So now we start to our right at the general form off our program. Two notes for guests, thoughts mortal, small and then thoughts, data. And in this, uh, cards we defined the foreign wars and then we right, Uh oh, it's gold and main broke in this possible. Write the script. So it's just like reminder Teoh practice. And I remember the our scripts and digital form off program. So as I said, we find our reporters here. So the question is, how can we define the horrible? So first thing was we should say that when we reserve a position in the central memory, we should remember the address, the number of the otters. So, for example, were reserved for the position off 720 address. And as a size off to bite, I should remember these numbers. 722 gets back for its later. So we can't, for example, reserve position off 720 the later we asked to get the archers off 330 for example, and we need we don't need this information. Actually, we need the information. Seven handed a 10. 20. So in this case, we cannot remember the numbers. So that's why we give a name for this. Ah, dresses, for example, the address number 720. So here the processor were do this operation automatically so you don't have to think about that. So, as I said here, we defined the variables. So here we puts the name of the probable. Actually, there is ah, rules for the variable name. We will talk about it in the next lesson, and they were defined bite or the size. So this is me and like, I want to find the one bites in the central memory. So one room we'll go back to this information in nature. And then we give the audio to end, for example. So the body were named and the size off the variable, and then we give the value. So this value, actually it's an initial value, and we can change it later and put wherever we want in the program. So if if we don't know what put us initial value. We need the question mark. So this is the end. Thank you. And see you in the next lesson. 9. 09-The rules of naming a variable: I know everyone. What comes? You are Listen, this isn't We're going to talk about the conditions off defining affordable. The first condition is the letters off The variable should has only the English letters and the numbers from 0 to 9. As we can also use the ads and the school. So any letters from any other language are not accepted. The second condition is it shouldn't started with a number. So this is a mistake and the suffering with as or underscore are accepted. This is most problem Also, the number off the letters off or character that used in the variable should not be more than 31 letters. And in our case, we have ah six. So this is a court. The other condition is that language its case insensitive. So right in a variable with this case in the same with this case and also the same in this case. And also it the same with this so right in the variable in lower case or upper case it the same. So this is the end of the dissonance. See you in the next year, then and thank you 10. 10-Size directives: I know everyone and one come to our lesson. So and this is and we're going to look about the size director. So what is the size of? Simply These are the size start to in the privilege. Listen, we explained the variables, so we said that we write the horrible and then site director and then the value. We have also explained that the variable is reserved position in the memory that has the address and the size. So when we say variable, one defined by this is mean that we reserve the position in the memory that has the size of form bites. And when we say we're able to define word, this is mean that reserve the position off two bites in the memory when we say a variable three defined double. This is mainly reserved position that the size off for a bite and four bites means before rose and be careful. Four rows are consecutive, and when we save money before defined Quad War, this is mean reserve position off its bite or eight rows consecutive. The last one variable five define, then this is mean. We reserve position off 10 bite that's holding our listen. Thank you so much and see you in the next year 11. 11-The Constants: Hello, everyone, and welcome to this lesson in this lesson, we will see the constant How can you use them? And which problem does it solve? Let's suppose that we need to write programs that's calculates the circum plays and the surface off circle and so on. It's some kind of problems. We need the constants, which is the pie 3 14 that supposed that. We started to write our coat and in every time any discount stints were just resupply or divide or wherever by 3 14 So when I finished this program, I've found 3 14 everywhere. That's no problem, actually. But no, we won't change this number, for example. Some, for example, is Theodore, 30 14. I want to make it 3 14 28 So the problem here, we need to go back to our coat and we'll write 3 14 28 in everywhere find 3 14 So that actually practically is not used for and it's so complicated. And here comes the constant to solve this kind of problems. So where and when can we define this constant? We define the constant just officer the data. So in these parts with the variables and it would be better actually to define the constant before the variables it not required. But it would be better to do that. So the constant before the variables, how can you define a constant So the name of the Costin's and then you and in the end, the value You should know that when we define the constant, for example, here a pie and it defined here with 3 14 so we cannot change this value in our code here. So this is a mistake. Also, we cannot define to a constant in the same road, so each constant in different road the company is that the constant had the same rule with naming the variables. For example, it's cannot begin with number in the first, and the number of the character should be less than 31 and should content only the English letters and the numbers and the art and the other school. And this is it. So this is the end to you in the next lesson 12. 12-Types of the numerical values: Hello, everyone. And welcome to this lesson and the lesson. We're going to talk about the data types to start. I want your mind that we cannot write two variables in the same line, so each variable should be writing in different line. So, for example, this writing is force Also, we cannot name two variables the same name. So I think this is a logical In the previous lesson, we said that it defined variable. We should write the name of the variable and the side directive and the value. So what are the possible values that we can precise? So we can basically write values or letters or array. Also, in this course, we're gonna use the define byte and defined on the final word more so the other side directive may not need it. And about the value we're going to use more the number of types more than any other time in this course. So we have three types of numbers. We have the decimal numbers and we have the Bonny remembers and we are the exact decimal numbers or the head senators. So how do we find each of them? So, for example, 15 is the symbol numbers and we define it life. This example, the Bonny remember, should contain only the ones and zeros. So for you, right? For example, two or three in the Bonny remembers. This is mistake. And then we are the letter B reversal of January to write its upper case or lower case. As we said, the long wishes incentive, the other reported in in the Bonny remembers, is the size. So, for example, when we have different bite so the neighbors should not override eight bits or eight numbers and the mean of numbers here is zero and one buying your remember. And here we are, for example, for number we can odd for members, for example. But for example, if we are number one here, this is wrong, and that's what you caused overfill. So this is me in the size off. The body is bigger than the size off the body that's were reserved in the memory for this more values. The body should be between 288 and minus 128 or and including these two values. So we're writing, for example, 256. It would be a mistake and writing mindless 129 or 130. It's a mistake as well. And this is for the boys on the same thing for the world. God here. The Inter for is 60. 64,000 and 536 and minus 32,000 and seven handled and 68 on talking about the size world. So in the Bonny retyped, the value should not override 16 bits. It's paid for baby end 16 bits for the W Oseola, and now we talk about the exact type. The first rule is that the value should be writing in two members and second rules is that it should be end by H Leisure. So this is an example 12 age. This is value in heads at this moment that the resort is that went over body started with a lesser like, for example, f or a Here. We should add a number zero in the first. So it's just like informing the processor that this culture is included in Texana value. So if it, for example, I started with the number we don't have to all the zero so zero is would be other pony when we start with the letter. So our money, what you have done intake that this imam value Our body should be finished with the letter age and it should content only two numbers. And if we started by leisure, we should out the sit number zero and the same thing for defining world. We finished by the age. But here our body should not override for members. And we also add zero when we started by lesser. So, for example, this writing is accepted also this one. So this is the end of Howard isn't Thank you so much and see you on the next list. 13. 13-Data registers: I know everyone, and welcome to our listen. Today we're going to talk about the registers. So we said that this processor has 14 registers and each register has to bite. So the size of the register is two bites or 16. Bitch on. You said that we would go back to the surgeon sisters, and here we go to a are listening is about these registers and specifically the data registers the register thoughts we used in general a x bx, c x and V X. So the producers has to bite our 16 beats like the older investors. But this is users has a specific thing that we can separate them into two or the producers . Like, for example, I x we can spirited t o i l and each a low and a high on the same thing for BFC X and the D X. And as I said, I use this registers for the mathematic operations and also the logical operations. So this is the end of it. Listen. Thank you and see you in the next year 14. 14-Mov instruction: well over one or welcome to this lesson in this lesson. We will write our first program. Remember that you should know that designer made 14 registers for thes maker processor and each register contains 16 bits as they made set of instructions and they are the instruction set. So what are these? Instruction says they are some instruction that difficult processor is able to execute. For example, the auditions obstruction the division, the orth and then so on. In this lesson, we will say the first instruction which is move the general form of this introduction is move destination comma source. So what is the role off this instruction? It will move the value off the sores and save it in the destination. Before explained this instruction, you have to know that each instruction should be writing in different role it the same thing with the finding, the body balls and the constant. Now we move to the conditions off using this instruction. So firstly, the destination should be register or a variable. It's cannot be a constant. So, for example, if we're right here, move, See there for example five. So we saved the value five in the constancy. This is a mistake. The cost that should never be in a destination. Because, as you said before, the constant never changed. The second Tiny's in the source week and rights at the viable can rather register and the constants. But there is one exception here. If there is a viable in destination that we cannot find another probable in the source or if there is a viable in the source, then we cannot find ah valuable in destination. So if, for example, right move more, one want to. This is a mistake, so it's impossible to find a viable in the source and in the destination in the same time. The third thing is the size, so the size in the destination should be the same thing with size in the source. So of the destination has a spit, Then the suit should have a bit as well. Now we move to some examples to make it clear. So let's ride this example. Move a l 15. So we saved the body. 15 Inderjit, sir. A l and actually in the service we can write the value in the Bonny resistant or in a decimal big that this him all and so on. And if you have a problem with the binder system and take the dazeem or you can just go back for the previous lessons, let's humiliates our program And here we get this answer fees. So here we have Teoh windows on the right. We have our code here, and the instruction thoughts will be executed in the next time is indicated by the yellow corner. The instruction moved A l 15 will be executed. And as you see here, zero f introducer A l you should know that the body was here are in the exact decimal. And if you want to check from a party, you you just go to click on contractor and then you write the number or the body of that. Do you want to check for example here, zero f in the exit decimal. So it's 15 in the dismal as you see and it the same value thoughts we have right in here. For example, if we write 11 and exit decimal when you click on emulate, so here, 11 in the a l. And it is no problem as well if you want to write it in the binder system on here is three three index of dizzy. More the check. That's if three and exit the symbol of the same thing with 11 in the boundary. So three in the eggs are on here is as you see, it's 11 in the boundary, and the zeros on the left has no sense. Let's use your example now. So that's right. For example, move. Ah, for example, move a l three and then move, for example, D. H. And it's a, uh, a l. Let's see that. So the first day peas three in the A. L and then we will save the value. But easy. The A l we save it in a pH. So as you see here, 38 at the age. No, let there's the condition off the size. So as we said, the size off the destination should be the same thing with size in the source. So, for example, that's right. Move the age a X check that on here, as you see operator do not much. It's bit and 16 bit register, so that means that the size into the age and a eggs they're not the same. So this is the end. In the next lessons, we will see Mawr examples and everything will be clear and easy. So see you in the next lesson. 15. 15-Mov instruction example I: Hello. We wanna would come to this lesson in this lesson. We're going to see an example about the instruction move that we have seen before on we will summarise what we have seen about the body balls and the constant. So, firstly, we defined a constant C with a body of 15. And then we define two variables, some sort of mistake here to you. So we defined two running balls for one and part two with size bite, and then Bar one is equal to 12 and in 40 will save the body off the constant C. And in the end we do the permutation. So we save it of rto the body or the part one. And we save in a bar. Want the body off the war too. So therefore one will have the bar you see and what you will have the value. 12. So we opened the EMU nature. Let's start right in here dot model small and then thought data. That's code made Brock and then main and be and then the end. So in the first, with the find the constancy with a body of 15 it's easy. So we define the constant here. Well, right. See the name of the constant and then eq you and then the for you 15 What is the second thing? So we defined two variables we want and what to with size bites so far one defined bite And in the initial value we will go back for its letter and then rto different parts and we will go back for the initial values letter as well. Then we save 12 in the bar one So it's well as initial value for far one and then in the party We saved the body off the constant C. You should know that you cannot write it in this way. So this is a mistake. But we will leave the question mark in this case. I do not know the value off the bar too. And we will save the body off of rto your end execution off the program. So the first thing that we dio move I want to And then the body of the constants C before that Actually there is instructions that I want you to me more rise now and we will explain this instructions in the next lessons. So when you deal with the variables. You have to write these instructions. So you're right. Move. I eggs, data and then more. The s a X. So you need to memorize that. So, in the next lessons, we are going to explain why we do that. No, we made a the program. The 1st 2 instructions are not important. Actually, The second step, we save the constancy in the barn able to. So where we find the valuables here in this window, you go down. So there is a vargas there. You just click on Farr's and here it shows, or the variables that are available so far, one and war too. Now, if you click on single step, it will save the 40 15 on the far too. So zero f is his index a decimal? If we check that, we go to the computer zero f and there is 15 as it was expected. Now we leave this operation. So here we do the permutation. So we do the permutation between the two variables. The value off the far too will be in the far one in the body off the for one will be in the far, too. How Can we do that? So here we need a register on let B A X. Actually, I cannot do that. Move Var one part two. As we explained in a previous lessons, we cannot do that. That's impossible. So we're right. Move a x far one here. I expect to have a mistake. So guess what is it on here? Or print? Do not much. 16 bits Origin, sir. And aids Bates Audrius. So I X has 16 bit on Hvar. Juan, we defined this us bite. So in this case, we have to write a l. The next step we save the value off for two in the bar one so move far too. Bar one. And here we will have a mistake. As you said, this instruction is wrong. I cannot write. Move two variables. So now what should we dio it easy? We will use a register who used to register for example a h move h far too. So now the a l has the body off the bar. One and age contained the value off the bar too. All we need to do now move. We want to a l and then right Move You are one a h. So we did the permutation here. So the body off the bar one was in the A l. And now it's in a war two on the same thing For a age. The body of the party was in a H, and now it's in one. Now we click on imitate, Let's see. So the 1st 2 instructions and most important, that their destruction we did it before. So if you click on a single step and hear their age in the bar too, which is the value 15. So then we saved the father of the 41 in the A l so here, as you see, see, in the A l which is the same thing with 12 if you check here, see index a decimal on her just well into this in more. And after that he said the body or the rto in the a h So here in the a h, we have zero refugees 15 and now we will save the body off the A l end of our two which is zero C or 12. So here zero c in the far one. Now we saved the value off the A H in the far one, which is 15. So zero f And here zero f end of our one. So everything is done. There is no mistake. I wish everything was clear. See you in the next lesson. 16. 16-Mov instruction example II: Hello, everyone. And welcome to this lesson and this. Listen, we're going to show another example off the instruction move. So in this example, we have the volume three and registered eggs, and we have the Volume five and register the X, And we have also the value seven and urges L C X. And what are we supposed to dio is to make a permutation between these three values. So those in the fund a result you got seven in the register eggs and re good three in the register BX and we could also five and they register. See, ex action is idea is sample. It's only need is another register and the, let's say the register the X So you start, Let's open our image nature. We start with those more than small and then the data and moved to the code. And actually, in this program, we can dilate the part off that they said, because actually we don't need any variables in our program, so you can remove it. So after don't go to the right main Prock and in the last roads and processor and and so we're going to write in a man Prague person they were going to write. Move my ex tree Teoh Stock the volume three in the register X and then removed. Teoh, move the X five Teoh stump value far beyond Just be X and the last rites and move C x seven to put the body seven and register six. So our idea here is to start with the brain. The value off purchaser A is in the register. Did the X and rights move the X A X So that's in the next step we can write. Move X C x So what we did here is we talked the value X in the register the X so that we can stop the value off the register, see X in the register eggs in the same time, we don't lose the volume off a it because we thought already in urges or the And in the next step we wanted Teoh, move cxb x! So this mean we stop the value of the register BX and the register See ex And here we don't have to worry about the value off the register, See, X, because we served its in the register X before, So this is mean the value off CTX, which is seven. It's become in X and also the value of V X, which is five. It's become in the register, see, ex. And now we go back to the value that we have saved in the reduced er the this is what the volume off just eight x three. So we right move be x the X And here we finished our permutation actually. So if we were on our program here is resolute in its in life Our a gesture with the values three in X and five in Vieques and the body seven and they registered C X, as you see here. So in the next step, we said the value off the register a vaccine, the X and the value of C x in the eggs And then we saved the body, or VX in the reducers e X and the last ingredient that we saved the body off the x intelligencer Vieques. So the final result easier seven introducer X and the the Volume three in digital be eggs and the Volume five and register see ex us wanted to dio in the first time. How do you see here and the check here. So, yes, 70 x trian, Vieques and five in six. So this is the end of the lesson and see you in the next list. 17. 17-Xchg instruction: Hello, everyone. And welcome to this case. And this doesn't We're going to see ah, new instruction. She's ah, exchange or X C age. So what can we do this instruction? So, actually example the rule off this ah instruction exchange. It's only make the permutation between two registers or between variable on a register. So let's give an example. For example, we give move Ah a l five and we rise and move the l seven And then we writes a exchange i l b l So we make a permutation between the two registers later on this program. So five in a out seven in the help and in exchange i bl so it's become seven in that I have on five and b l a C c. So now let's see, what are the conditions off using this instruction? So, for example, is chained operated one and operates you. They should be variables. There should be a Constance I think is obviously so rising. For example, exchange 57 This is totally wrong. It's not logical or let drive. For example, it's change a eggs and seven or exchange 12 on the variable one, so they are totally wrong. The second condition is the size. So the opened one and operate to should have the same size so one bites or to buy, for example. So writing, for example, is change a X and they b l. And this is totally wrong. Last condition is that you cannot make an exchange between two variables. So arising exchange portable. One variable to is also wrong sentence. So it's just the end of our lesson. Thank you and see you in the next list. 18. 18-ADD & SUB instructions: Hello and welcome to this lesson on Stenson. Going to talk about the instruction at there is a problem. So the general form of our instruction is at destination suits. So simply this construction is going to odd the value of the source with a value off the destination, and the results will be in the destination. So let's give an example with us. Uh, let's say, for example, move a l five and move the air three. Let's hade a l would be. Also we rust at a LBL and here we expect the results us eight in the register air. So here, if we're on our program as we see five in the A. L and then three in the PL and here is in the end, hes in a register a oh, now to talk about the conditions off using this instruction first of the the destination should not be constant. So, for example, writing add five 12 and Susan mistake and same thing with writing a l or add the 5 a.m. or at five a X for at the five of our variable one, that's all wrong. So the destination it's can be a register and it's can be valuable as well. But we don't have any problem with the store, so it's can be a constant and variable. And the register obviously so at, For example, at a l five, it is not a mistake. And also at the a l d l true and also writing a M one. It's much problem. The only problem that we have is when we get the destination is variable, and this is also a very poor so this can never happen. So actually we can do that. And the other condition is the size, obviously. So if the destination has one buys the story, it's also should have one bite, actually. So writing, for example, at my eggs bl it's wrong and writing at Eggs Vulture is wrong as well, because, uh, exit has two bis and variable. One has only one boys. The other instruction off. This lesson is subtraction. So writes up destination and source. It's actually the same instruction with but his subtracted service from the destination on the final results in in Destination. And it's all the same conditions with using the instruction at. So that's right, For example, sub d a l b l. So that's wrong. Our program. Move a five on a movie. L three have lost any stops. A l VL. And here's the result Teoh and register a. 19. 19-ADD & SUB instructions example: Hello, everyone. And welcome to this. Listen and justice. And I'm going to give an example about the instructions, the increments and dig governments and the ***. So it's not going to do is a small program and follow the steps first. Today we define the number one as a bite with the body, you seven and then we to find never to a za buys with the volume three and next we should have the result of a number one is the number one plus two. But we should only use the increment instruction and they're the number two should be equal to one, but using ah detriments instruction on the last thing that we should do is to define the variable death as a bite with the body that will contain the operation number one minus numbers here. So this sauce our program So here, uh, as you said, you started more than small and then data, and here we find our variables. So, uh, we start with numb one different Barts six and then I'm to define bites. They and we moved Teoh death defined by zero. Actually, we made zero because when it is as a result off the operation off obstruction. So you go to a man from so in the first since our program is there on with the variables. So we right, move my eggs at data and then move the S a X. So first city, we should have the number one is equal to number one plus two. So this is when you should ANC increments our variable twice. So what should you rise? We should write increments and number one and then we're pitched again. Increments number one. In the next step, we have the number two should be equal to one. So we have before about number. The body off number two is three and with using only discriminates, we should discriminate the number two twice Also So which our program and you're right D agreements number two and then determines number two so that our results will be one. And in the last thing that we have to do is the number one minus numbers two. And the results were be in our body of or death. So here is our idea person even rise to move l number two and then the right destruction nigari. So when you get a L and then writes addition instructions. So at a l know more so if someone asked why we did like that, The idea is sample. Actually, so we know about this. Obstruction or operation is actually an addition. So right in the number one minus Number two is the same thing with writing number one plus minus number two or a *** of number two. Now let's run our program so it goes wrong here. Rapport. Amateur determines number two. Let's see your is a mistake. So where is the problem? Oh yeah, and finding our variable number two. So it's not you're not. Number lets you know. So yeah, there we go. So we have university increments in number one, so it's become six, and here is become seven. And then we moved. Teoh declare its instructions. So seeing a step here gets our results easy to and saying yourself, And here's our result is one us. It's a progressive, and I moved to the last part. So said the body off for the very born unto in the register a l the one you want used in the register. L know. And then knicker of l the what you wanted to became minus one. If you want to check, you go to convert Chur. And here he writes of And the result is minus one. The next single stuff. We are two values And of course, the results in the register l So we save the result in our variable death. And he goes here the value seven as it was expected. And here is the end of our program. And yet also the lesson. Thank you and see you in the next election. 20. 20-INC DEC NEG instructions: Hello, everyone. And welcome to this lesson is this. We're going to see another instruction which is in increments. The general form off this instruction is increments destination, which is mean odd one Teoh destination, for example. The value of destination is five. So when we were I increments estacion, it would be six, actually. So let's rise. For example Move. I am five and then we write Teoh increments A l So this around our problem on here is a move a five and with increment l As you see, it's ah six. Let's see another example off variable whose ample rice increments Ah, bar. And then we have defined our before that has the value six. And also it defined us a za bites. We click on a bar to show variable. We get the results seven now to talk about the conditions. So what are the conditions off using this instruction? So it's construction obviously does not accept the Costin's so right in increments 12 has no sense actually. So this instructional except all need the variables and the registers and it doesn't matter with the size of one bite or two buys, it knows problem on our so writing, for example, or increments A X or increments a l and there is no mistake here. Now I want to talk about another instruction. But she's ah detriment. And the rule off this ah instruction is the documents the destination. So to subtract one from the destination that see an example off Move I x five and then end equipments this register. So a documents eight x so five X and then with the documents, it will be four, as you see And this instruction does not accept the constant aswell. The last instruction is ah, *** construction. So this uniform with this instruction is ah nigari destination And the main rule off this instruction is to multiply the value in a minus one. So if we are, for example, a positive value in the Register X and the result is will become negative results. And if you have a ***, results will be positive results. Let's see this example. So I X has five and *** of a X has have, uh, Bay project is in our converter. So she was actually a 16 bits because you are working on X if itwas a l, which who's eight. So here is a B, and the result is malice. Five No, he puts ah minus five in ah X. So, as you see it said more than five in eggs with single sip and the final result is five. And you can also use the variables here. So there is no worries. So this is the end of our listen. Thank you. 21. 21-INC DEC NEG instructions example: Hello, everyone. And welcome to this. Listen and justice. And I'm going to give an example about the instructions, the increments and dig governments and the ***. So it's not going to do is a small program and follow the steps first. Today we define the number one as a bite with the body, you seven and then we to find never to a za buys with the volume three and next we should have the result of a number one is the number one plus two. But we should only use the increment instruction and they're the number two should be equal to one, but using ah detriments instruction on the last thing that we should do is to define the variable death as a bite with the body that will contain the operation number one minus numbers here. So this sauce our program So here, uh, as you said, you started more than small and then data, and here we find our variables. So, uh, we start with numb one different Barts six and then I'm to define bites. They and we moved Teoh death defined by zero. Actually, we made zero because when it is as a result off the operation off obstruction. So you go to a man from so in the first since our program is there on with the variables. So we right, move my eggs at data and then move the S a X. So first city, we should have the number one is equal to number one plus two. So this is when you should ANC increments our variable twice. So what should you rise? We should write increments and number one and then we're pitched again. Increments number one. In the next step, we have the number two should be equal to one. So we have before about number. The body off number two is three and with using only discriminates, we should discriminate the number two twice Also So which our program and you're right D agreements number two and then determines number two so that our results will be one. And in the last thing that we have to do is the number one minus numbers two. And the results were be in our body of or death. So here is our idea person even rise to move l number two and then the right destruction nigari. So when you get a L and then writes addition instructions. So at a l know more so if someone asked why we did like that, The idea is sample. Actually, so we know about this. Obstruction or operation is actually an addition. So right in the number one minus Number two is the same thing with writing number one plus minus number two or a *** of number two. Now let's run our program so it goes wrong here. Rapport. Amateur determines number two. Let's see your is a mistake. So where is the problem? Oh yeah, and finding our variable number two. So it's not you're not. Number lets you know. So yeah, there we go. So we have university increments in number one, so it's become six, and here is become seven. And then we moved. Teoh declare its instructions. So seeing a step here gets our results easy to and saying yourself, And here's our result is one us. It's a progressive, and I moved to the last part. So said the body off for the very born unto in the register a l the one you want used in the register. L know. And then knicker of l the what you wanted to became minus one. If you want to check, you go to convert Chur. And here he writes of And the result is minus one. The next single stuff. We are two values And of course, the results in the register l So we save the result in our variable death. And he goes here the value seven as it was expected. And here is the end of our program. And yet also the lesson. Thank you and see you in the next election. 22. 22-From binary to hexadecimal: hunt over one. In this lesson, we will see more details about the numbers. Firstly, we should know that all the data in the computer are in the Biota system, so any information is saved in the computer and represented in the battery system. So if you want, for example, destruction moved. Air five, we'll find a out this value 1010 and so on. So this is five in the value of the system. The second tenis. The data has no meaning without based representation. What does it mean? That let's say, for example, of someone What does this mean? The value? 101 for you? Maybe you would answer it just the value. 101 maybe another one who will answer you. That is the emergency number. Maybe another one who will tell you that it's an office number and it's a one. So that's why we should precise their presentation pace. For example, here the Value 100 a one it's writing in the boundary system and the in form addition will say that the same thing with five in the decimal here, the older men is since we are using the exit system. We should see the representation based off the system. Let's take an example about that. Let's suppose that a l has this for you. So how can you convert this for you to the exit decimal? So firstly, we separate the register into two parts. Each part has four columns. So, for example, if we have here a X so we separate the register into four parts. Each part has four columns aswell. The second step we take each part supportively. So in the first you take the 1st 4 columns which is there 101 We converted to the decimal system. And we do that by the old way. So one by t o to the power of zero plus zero by t o to the power of one plus one by two to the power of teal blah zero by two to the power of three. So the power is increasing underside from the L SB to the MSB from the first bids on the right to the first page on the left. So we got the result as one la zero plus four because two to the power of two is four plus zero, and upon a result, this fight the second step. We take the second part, which is the 2nd 4 columns. So it's 0101 and we do the same thing. So zero by two to the power of zero plus one by two to the power off, one plus zero by two to the power of to plus one by T O to the power of three. The final result is zero plus two plus zero plus eight, and it's equal to 10. So if we get the value 10 or more 10 11 12 13 14 15 This values were presented by the letters so a, B, C, the E and F In our case here we got 10 and it's the same thing with a so a into exit decimal and in the last thing we just throw the integration by the two sides. So the left side and the right side. So five on here five and then a to not do any mistake. We just are zero on the left. In order to indicate that this for you Ease in the exhibit, Seymour. So I wish everything was clear. So you in the next lesson 23. 23-The difference between the signed and unsigned numbers: Hello, everyone. And welcome to this lesson. This doesn't actually we're going to continue the last lesson. So as a reminder off the last lesson, we said that all the informations are presented by the monetary system in the memory. We said that information without the best representation has no meaning. In this video, we're going to talk about the memory limits. So we figure out what is the memory limits about giving some examples? So let's say that we have a program that they're only with the ages off people. So you cannot find actually an age off people that has a negative value. So any *** values is wrong thing. So we're only then with the positive values. And here we are in the case, off inside values. This is me, and the values that has no science are only the positive values also have in a bit, or values should be from 0 to 255 and in the 16 our bodies should be from 0 to 65,535 also in our general rule in and bit the values it will be from 0 to 2 to the power off and minus one. If you see an example, so it's give this example. Move a l 255 and then we odd to to this register. Let's see what's gonna happen. 02 And then So you goes one of the results in the exactly same. Or if you want, check and how temperature we will find one also in December. Also 255 plus two. This is no spoiled, actually. So here is on example, off our memory limits. So this is because we had 255 max value and when we added Teoh to our value, we got wrong result. So our memory cannot accept more than 255 as value. So if we are anything to 255 result for sure it will be wrong results. In the second case, we have silent values, So where the values is can be positive and negative. So here we have in a speeds the values from minus 128 to 127 and for 16 bit we have the values from minus 32,000 and 768 to 32,000 and 767. The general rule is for and this we have minus two to the power to end minus one until two to the power of and minus one minus one. Let's see an example here, so I'll give an example off Temple moved a 127 on God to deter geezer ao. Unless you're gonna happen because the value of 81 chickens in the converter 81 and here we have in the signed one years minus 127 and this is wrong results. So this is because off the memory limits, so we have the max value is toe 127. So if you got any positive on you, it will be wrong result. Now, let's see the last example. Let's give a *** of values example minus 128 in the plus minds here, for example. And here we go. We got this result seven e no tricky and 70 and things of this Seymour, it's going to be 126 and signed value, and this is impossible minus 128th. Flaws minds to it should be minus 130. So, no, I think everything is clear. So anything president off the max or minimum values is going to be for sure. Wrong results. And this is definition off the memory limits. I hope that it waas clear. Thank you and see you in the next lesson. 24. 24-How to choose the right size for a number: Hello, everyone. And welcome to this video in this lesson, we're going to explain how to choose the right size in our programs, and we're going to make program that they are with the age off, someone so create variable age, not contained the age for you off someone. Before we defined the size off this value, you should precise the type off this value first. So, as we said before that, the value has no meaning if we don't precise the base off representation and all the informations are represented by zeros and ones. So if you don't precise, what do you mean by the zeros and the one? So it's just like nothing. So here the age will be, ah, value with numbers. The second rule is that you should know if you're value except negative, and positive bodies are only the positive. So here you are, between two cases the sign and the ensign and our program, the age. It's always positive value show. We will take the ensign for you because we can never find the age with *** value. If you remember, we said the ensign values, it can be from 0 to 255 for a bit. So this is the interval off eight bits in the inside one years. So which was a bit because we can never find age of someone but your press 255. So it is basis enough for this value. If you create another variable, for example, this valuable represents the let off buildings in centimeter here. Personally, our value is the numerical values. So the second thing, the lamp in central measure is going to be more than 255. So it's bit here is not enough for our bodies. So we're going to choose work, which has the max value as 30 point thousands of 535. If this is not citizens, we're going to choose quarter word. The idea is to know the match of our value, and then we should precise the size that is arrange and surf isn't for our max value. So in the 1st 3 precise the type of our value and then we should know and figure out what is the max value so we can choose the right size for it. This is the and all for the listen. Thank you. And see you in the next this year 25. 25-The Flags register: allow everyone and welcome to this lesson and this. Listen, we're going to talk about Special Register, which is flags register suggested. Contain 16 columns. As you see here, there is my columns that has meaning and the other has no meaning. So this night corns There is Kerry flat, for example, the parity flag overflow flag in those my flags. We have six. Our status flags that are in red color and the other are control. Flies stays. It's nice, like zero. The sign flags scare reflects and the control facts that shop and direction place. The rule off the stage of flag is supersize the states off the processor after doing an operation and the control flags. It's controlled the processor after doing any operation. And, of course, we need to focus on the state of flux. So let's suppose that we have ah value 255 invariable number on its inside it for you. And let's write this program, for example, move a X data movement. DS ends move a l No agreements. Ao Oh, here were a mistake t was Oh yeah, the comer. If you go to put to come here Oh, are you? How? Here we are. Another comma. I'm sorry about these mistakes. So it's from the program. Single step, single step Here is our body. You in the register a r f f. And then the anchor met the value in gets in the end, 00 If you want to check, let's see 00 What is in the assign it value on it. Zero is wrong. 255 plus one. It's is not zero. So 235 plus one The resulting zero. This is a mistake. So there is a special flights that show the wrong with the results. There is also another flags. For example, zero flag not show that the result regards is zero. Read the sign flag that show the result that we got these *** value We we offer, grows more about the US and how it works with this flags in the next lesson. This is the end of the day. Send Thank you 26. 26-The overflow: Hello, everyone, and work on in this lesson. We're going to explain the overflow. And how does the floods work with this case? The first question is, what is the overflow? The overflow? Actually, it's ah. When the value suppressed a special value in the end off operation, let's start with an example. So here we have moved out 255 and inside of the case. And also we are did one to the register A l Let's see what's gonna happen. So what? Human does it. So we we have joined 55 in the register A l we have eight bit. So the max value is 255. So if we are the one, we got the result on zero. If want it, take it. We will find that in the assignment value is zero and 255 plus one. The result zero. This is wrong. So this is the overflow. It's run. The final results repressed the next value. And we have here the Mexico U. And we have here. The max value is 255 and from here we can conclude that the overflow is to type the sign overflow and inside overflow. And in both cases, definition does not change eso it's your present off the Mexico U or the minimum value. Talking about the flags here in our case, in the inside values the flag which will raise is the care flag. So if we click on the flags bottom, you see the floods here on and you see here the CF or the care flag has the number one with red coral and this is mean that we have, ah, overflow. So actually, the care flag, we use it to figure out when we have overflow in the inside case or now we see the overflow in the signed values. So here the overflow when we add a positive value to a positive for you that happened when we are negative value to any great value. So let's see an example moved a 127 and we are the two to the average is a rail on DA here . The result will be 81 and if you check in, the composure at your own is minus 127 and this is wrong because we should trust the Mex value. She's 127 if you go to the floods. And here we see that the I've got the value one. So this mean the F or the overflow flag? He's rised. Now let's see another example This try with minus 127 and then we are the value minus you with single cell because the results seven f if wanna check seven f and the DeSimone is in the signs. Value is 127. It's just totally wrong. Minus 127 plus minus two is minus 129. And here the O. F got one. So the overflow flag in their eyes and we got ah overflow case here. This is the end of the descent. Thank you. 27. 27-The overflow in NEG instruction: Hello, everyone. And welcome to this lesson and this lesson. We are going to see the overflow in negative construction. But before that, let's see, it's more monitor off the previous instructions on how came the flags be affected by thes instructions in the movie and exchange instruction. No flag will be affected for the ad on the sub instructions, all the flag will be affected for the instruction, an agreement and document All the flags will be affected except the C f or the care flag. Now the best of the negative construction. So how is the overflow with a negative instruction? So it actually happening when the body is minus 128 in eight bit a near the *** of instruction they all knew, decided numbers. The inside of numbers has no meaning. Let's check that. So here the overflow black is raised and that means that we have an overflow. So we will find an overflow if we have a spirit and the body is a minus 128 and for a 16 bits, it's happened. Actually, when the number is minus 32,000 and 768 Let's take this example aswell. A near the over flag is raised, so we have an overflow. And as a general rule, the overflow cases will happen in the *** of instruction when the body is minus two to the power of and minus one. Where N is the number off the pitch where N is the number off bits where this number is represented? So if we have a to write eight people have 16 were right, 16. I was everything almost clear. See you in the next lesson. 28. 28-SF ZF: Hello, everyone. I work on to this lesson and this isn't We're going to talk about this. Is that f and SF flats or zero flag and the sign flag. Let's see our example here. Move five and stop I five before the results is zero. So if we check the flags, we find that does that is rised because our result is zero. When you go to zero of the results, Mr Will be rice. If you go to the other gration, move the l three and remake this up five. So the results here is amounts to So if we check it was f e. Our result is minus steel in a sign of values. If we check the flags, you see does the S f is rice and go the body you want. So when we get negative results, does that effort Bryce or the zero Frank will be rised? Also, you should know that it's something extractions that does not affect on the flags. Like, for example, the move instruction. If you keep on the move a five or move a r minus five and we checked the flights, we find that the sf is not rice. So yeah, instruction move does not affect on the flags. And actually, the flags doesn't affect on destruction exchange as well. And in the last days and we said that we can check from the overflow states by the care flag for that reason exception for the instruction increments, for example. Yeah, a l do under them to fight. And I suppose that this is an in sand values and then increment a l No, Check that. And the flood here will not be raised. And the result here is no. So this is an overflow. But if you see here, the care flag is not raised by those that flock here is race because the result is not I wish everything was clear. See you in the next lesson. 29. 29-SF ZF example: Hello. Come to this. Listen. And this. Listen, we are going to use SF and that flags or zero flag and the sign Flak. So what are you going to do? We're going, Teoh. Define number one and number two was a bite. And then we're going to jail. It values off the variables and compare it on. This is all the using the flock to register. We should know that Number one is 1/4 number 21 Number one minus number two is 1/4 0 and number one is greater than number 21 Number one minus. Never to is positive. Number one is less than number two. Whenever one minus number two is a negative results. So we're going to see the results. If there is off zero the number one, it is 1/4 number two. If the result is positive, then number one is rated the number two. And if the result in negative so never want is less than number two. So all we should do is to check the S F and set a flex. So that's that's our program here. First lady, we define number one with fall. For example five what do you never to also the same body. So it started move my ex data and then Moody s ex. Then we said the number one in the producer right out on. Then we saved the number two and they're just bl we subtract the two values am from beyond . The results would be in a are when it acquits got happened. So it's single Step number one is in a all number two NPR. The result is so there is a result. If we checked the flags, we see that does that f is one. So this that is rice. This is me that our result A zero. So number one is equal to number two. The change The example. So we put for example, number one. We define its with 15. Let's see what happens. And here is the result Is that a zero on the SFe zero? So this is me and the result is positive, which is mean number one is greater than number two on In the end, try with for example, number one, It's one. And then let's go to check the floods on Here we go as F is one. So the result is nigari, which is mean number one is less than number two. So I thought that everything was clear. Thank you and see her the next lesson. 30. 30-PF: hunt over one. Hence dozen. We will see the parrot reply. So what is the role off this flag? And I suppose that we have this for you on the register A X And when we talk about the a X , we're talking about the A l and age. So let's supposed in this example, that we have this for you in the a X in the monetary system. So the party flag will work only with the lower part in this register. So with the 1st 8 bits or the exhibits on the right, so it's work with the low, it doesn't work with the age. So on what is indicating this flag? So it actually indicates if the Oculus number off the number one is uneven or not. In our case, here we have 1234 So the Oculus number off the number one is four and says it's an even number. So the flag will be raised if we have, for example, on all number than the flag will not be raised. Just one more thing. Zero is actually uneven number. So if we don't have any number one here, the flag will be raised as well. Also, this flag will not affect on destructions, move and exchange. Let's take this example. So, for example, move a X four and at a X one. So the final result is five. Let's see, but And here we got five introducer i x. If we check the flags on here, the party flag is raised project at a presentation on the barter system. So the number five in the scientist embers on It's actually 16 bit so five. And here is their presentation on the burner system. So the number one is repeated twice. But before that, we should separate this value into two parts. So 12345678 So here we see the organs off the number one on year, the number one is repeated twice. Teoh is uneven value, and that's why the party flag is raised. But actually this flag is can be affected by instruction increments. So I don't like the care flag. So if I suppose that we have construction increments, a X here so does around the program. The parts of flag is raised and there is no problem. And also there's no problem if the a X become a l so more air for increments ill. So the party flag will be raised. And here, as you see, the party flag is raised. So this is the party flag. I wish it was clear seeing in the next lesson. 31. 31-Introduction to the branching: I don't everyone and this isn't We're going to see instruction, which is very important. That is called the branch instruction. Before that, we should note is the manipulation of the program is sequential in our example. Here. The manipulation starts with move air five. It's ending with increments Ale. So we have moved their five and then we have moved over the five stop a RBL and then moves the old 12 at LBL. In the end, we have increments a l. But sometimes this order is not here for the sequential order is no. In all the cases use for, for example, I wanted to test the results after this Russian stop air PR. Let's say, for example, that the results is no. I'm going to jump Teoh increment a out. Or, for example, I'm going to go back to move air five. So this is how it's working. Actually, since how can we use the branch instruction? It actually jumping from an instruction to another? So what based the branch instruction? So it actually based on the name off instruction, for example, jump if zero and it also based on the disruption that's we want. You jumped you. Let's see here, for example, we have Jim zero and we jump to instruction label. So for example, if the result is no, I want to jump Teoh the instruction increments. Ao So what should I do? Actually, So all we have to write these two are the same name that we work before. I mean after the breast instruction which is label so right labelled before the destruction Increments A are so here label increments they are so here we have the results. If more we're going to jump to instruction increment are otherwise the program will be manipulated This a culturally and the next instruction will be moved cl 12 And here is tell the end. So let's immolates our program on here have firstly moved a five and then has be a fight and then stop a lbl and ah here The zero frog will be raised because we have the results zero. So, as you see, the zero flag is raised and it's got the value one. So here was Are we going to deal going to test the zero flag if it's not or not, So, as you see, it jumped to the instruction increments a L because the result is zero actually. Now, let's suppose that we want to go back to the first instruction. So we had to ride label and then Colin before the instruction moved AM five. So here, if the result is zero, we're going back to the first instruction to run from the first program. And here we have a problem, because the name neighbor should not be her beaded twice. Otherwise, our program will must be emulated. And obviously it is impossible to Ryan's actually. So we're going to add the number one, for example, to label so so here. If the result is no, we're going back to the first introduction. It's brought our problem. So you see, And, uh, the little front is raised and go back to the first obstruction as it's supposed to be. So what are the rules off defining label? It actually, the same rules off defining the variables. And actually, we have to type off the branch instruction. We have the conditional, and this is like happened when our condition is very fight and the other type is the unconditional and his happened absolutely, without verifying any condition. And here is the end off the listen. So you in the necklace 32. 32-The branching -Part I: I know everyone and work home to dismiss it in this lesson, we're going to see the first type off the branch in construction. So this type is work only with flex. So it does directly the states off the flags. For example, we have a J. C. We have also J O jZ, as we have also the negative form of the instruction. So we have the positive form and the negative form the positive form like G o R gem if O or ah, Jam PFC, for example. And she's mean jam if the flexi is raised or a jam if the flag as a sign flag is raised and this is a the negative form was a jam beef Morty. So this is mean jam If the flag C is not raised or we have a jam if the flexi is not released. So if this is for a wide, we jam to the instruction off and we follow the instruction. Now we're going to see an example about the overflow states in the inside and values. So we said that in the inside venues we have to test the guarantee flat to figure out the overflow of estate. So we have moved a all 255 and then we add one to the geezer A are. And here we absolutely we have another floor states So Jim IFC to the instruction over. It's verified 100%. So we would gem to the extraction om and put the only one in the register. TL, in case off the care front will not be raised. I would move to the next instruction, which is movie a fight. So we put the body up. I've interviewed Serbia. So let's give me that the program a single sip The Gerty Fleck is raised and reject you construction over which we will have one in the register. Dear legend the example so that the camera flag will not be released. So we put 254 for example and ah t job. The girl flag is not raised, of course. So we moved to the next instruction. Who she's moved the f I and then move the other one on This is it. Let's, for example, just the zero flag. I want this that the result is not more so. If the result is not No. I'm going to do some construction. So try this program. Definitely. Result is not not because we have 254 and the number one, So we check here. Uh, zero flag is not raised, so we jam to the instruction over and removed the 12 dishes. Her deal. Now let's check the parrot effect, so change our example. So we Raj, for example, while you five and register l and then at the number one. So the final result is fight. Check this number. So he writes the number five in the inside a condom and we have here in the bunker system the organs of the number one is too. So it's just mean the parity flag will be raised. So we write jam if P or Jeff charity to the instruction. However, So here the parents, if like, is raised and we gem to a disruption or which we were puts one in the richest deal at the end of the program because we have the 45 5 in the final system. It's even value because the occurance off the number one is to. So if we does, for example, jampp knots parity. So in minutes our program. So here the birds flag is raised. But we're going to move to the next instruction, which is moving at five. And then move the other one because we have jumping prosperity and the British flag is racist. So it's just the end of the lesson. Thank you. See you in business. 33. 33-The branching -Part II: Hello, everyone. In this lesson, we will see in conditional branching. This instruction has this form GMP. And then the label is like champion without any condition. For example, jump begin. So here we go back to the label. Begin where we have the instruction. Move air five. So champion without any condition. For example, if we're right, Jampp met. So we'll jump here without this in any flag or anything Jeff met on here. He jumped to the level net where we have moved the air one and then the rest of the instructions. Or, for example, writes jampp and F. You have to know that this introduction read it stops the program or the prosecutor will. We are. And we will see these instructions in the next lessons. All you have to know now is that this instruction will stop the processor where you are in , which is here main. And here we have jampp and F. So we'll jam to the end of our procedure. Let's check that jump and half. And here we jump to the end off the procedure or the end of program. I wish everything was clear. See you in the next lesson. 34. 34-Branching example -overflow 1: I know everyone and this. Listen, we're going to see an example of us taking decisions based on some special flex going to define our number one and number two as a bite. And actually number one and number two are assigned numbers. So what should we do? We should add number one to number two. And the result? It will be in the only if there is an overflow. Otherwise it will be zero. Hey, we're going to use the care flag. Actually, you said before that we used the careful are contesting the overflow. And here's our program. We have number one bombard 215. Then we have number two down by 10 6 Then we move to move a l number one and then and I O number two. Oh, actually, I forgot destruction. Here they is, Theda, Sorry for his mistake and Moody s A eggs. So then we're going to move a L number two to L. A. And then we add number two to number one in the reduced air. And here, if we're going to have an overflow, I'm going to jump Teoh f or over, and we're going to put the body One in the register, the air. Otherwise, if there is no overflow going, Teoh continue the program. Nobody. And so to put the value zero in the use of the era in that, then we jump to end. And in the end, F we have, ah return. So the end of the program Actually, Sonus imitate the problem. So go number one of their own. Number two be added number two to A L. So let us they care. Flak on the car flick is raised So we're going to gym Teoh os on Here we go. Move the want to dio So the continent body one one hears the end off the program Now try to change our example Trust for example 128th in this case. Actually, you don't have overflow. Let's check the results So checked care flag and you see the care flag is not raised. We're going to continue our program normally So move d l zero and then we jump to the test and the n f is actually the end of the program. So this is it regional dwells clear. See you in the next lesson 35. 35-Branching example -overflow 2: all over one and its lesson. We are going to see an example about taking decision in the overflow with assigned numbers case, we have to define the number one and number two as a bite. Actually, they should be assigned numbers. After that, we save that. The one if there is an overflow and we save zero and there is no over flow. So here is our example a number one defined by 12. And then number two of the phone bars minus five. And here we have a movie out Number one and I'd be l number two. The final results will be seven. Therefore, there is no offer float. Check that. And here the overflow flag is not raised. So there is no overflow case. And therefore to save zero into the l again jampp at F to end the man procedure. So here are two the second example Let Roy Moore handle on 27 and the number five So here, Absolutely. We have an overflow because you see, repressed of audio 128. And here the overflow flag is raised. Therefore, to chance off sample where we save one in d l and then the end of the prosecutor, the last example here. So minus 127 and then minus fight. And they will have an overflow case as well because we surprised the limits, actually. And here the overflow flag is raised. So we save one into the L to indicate that we have an overflow and then the end of the program. See you in the next lesson. 36. 36-Branching example -comparing numbers: I know everyone in this. Listen, we're going to see another example taking decisions based on the results off flags so going to define number one and number two is a bite number one and number two are signed numbers . So they were going to dio going to compare number one and number two. Number one is equal to number two. So the elder content zero number one is greater than number two. The l should haves body one. Number one is that the number to the air should contain the money to hers are problems. So we define number one with the body 1 20 Find number two as a bite and content. Also the body five. So move a X data and Moody s E X number one in the registered mail. Never too. And there's absolutely number 100 shoe and jump if zero Teoh. So this is actually equal. Actually, it have the l zero and then we jump tow anti have, which is at the end of the program. So here, if the results is zero, we're going to jump Teoh equal. I'm going to put zero in the register d l If the result is no. Zero. We moved to the left instruction, which is jump if no time. So here we're going to jump to stop only one we have. The result is positive Jump if Lord sign So with instructions up with is contained. We're going to put one in the register TL and then jam, and we jump to the end of the program. Otherwise, if the result is not seek war and it's not positive so the results, it's ***. So we were docked. We moved to the next instruction of He's moved the air, too. And then Jim and F spend the end of the program. That's the media, the program. And he was gonna so move ale number one and then subtraction off, never to remember one. And in the Czech zero flag, so zero flag is raised. This is when you're going to come to equal. And here we jump to your move. Zero to the l A. C the end of the program. Okay, so here the results zero, you jump to equal. Let's change our example. So it puts every 21 in number one and see what's gonna happen. So here is your flag is not raise because the result is not zero. So then it's construction will be jumping, not science up. Let's check the flats. So here the same flag is not raised. So this is mean jump people, scientists replied. So we would jump to stop construction on the air. We put one in the reserve, the l jump and us. Now let's see the last example. Let this example one in the number one. No. Yeah, not zero. Of course she's not. Zero Jacob Goldstein. So here's the site Flag is raised because the result is negative. So jump people sign is not verified. Just we were going to move to the next instruction so we could do in the research tail on. We jumped Ew and F and the end of the program. I hope it was clear. See you on the next list. 37. 37-The branching -Part III (1): I know everyone, and this doesn't we're going to see another type of the brain machine instructions. They start concerning the comparison. We have the cooperation in the sign numbers and the ensign numbers, and in this lesson, we're going to see the inside her numbers. And what does the sign numbers in the next lesson? These instructions as the positive form and the need reforms. The positive forms. Assisi here, a g A. It's a job. If it's a boat G eight, you Jeez, John. Profits above or equal and a GV is jump if it's below and we have here g ve, which is jump if it's below or equal. And in the end, we have jump. If it's equal. As I said, these instructions, it's only for the assigned for news. If we use them for the sign values, it will be wrong results to understand more this instructions, we should understand this statement. So we have here is greater than B is the opposite off is less or recording be. In other words, a is greater than be. It's like we're saying is not less or before than be, and if you say is not greater than be in the same thing with a is less for equal than me. So we can notice the gem if about it, like Jim below or equal. And here we have a is greater or record and be it the opposite Off ST A is below, then be so. This is like saying a is greater or before then B is the same thing with saying a is not below them be and saying a is not richer or recording B is the same thing with ST A is below them be. And from here you can notice the jump if above, or equal that the same thing saying jump if not below. So what can you say for jump it below? What is the call off? A is below them be here we see that a is below them. B is the same thing with a is not greater Orrick Ward and be so jammed below is equal to jam, if not above or a poor. So what is the equal statement on Jambi? Below or equal? And, as you see here, James below or equal in the same thing with jam, if notable in the same thing with jam. If notable The last is Russian jam with equal. We have only the the opposite form which is jam, if not equal. So here is the end of the lesson. Thank you and see you in the next lesson. 38. 38-The branching instructions in the unsigned numbers -example: Hello, everyone In this lesson, we're going to see Gretchen attractions in comparing the inside of bodies. So what are we going to dio? We're going to compare the air with a age. So if a L is greater than a edge, the bar want should contain the body. One else. The bar one contained the values there. Here is our program. So with this morning data or one given bite, it's unknown because we don't know the initial body off the very bored or one. So move a data and the eggs will stalk the body. Five introducer A l and start a body of sex in the digital age. And here we have new instruction. It's compare. So it's instruction. Actually, it has the same work with self destruction. The only difference is that stop destruction. It's thought the result on the review, sir. Air One decision instruction. It does no stock anything. So it's affect only on the flats. So we're going to compare a l with a age. So it's a Alice about then a age. We should stop the body one in were one, as you see here. Yeah, John, with a bow. And we're going to jam to the instruction abo which we're going to stop the body one in the table one. So if it's below going to move to the next distraction and she's moved variable 10 So we stopped the value zero in the report for one and then we jump to end. FG is the end of the program and actually we can change the instruction. Jeb about Teoh Jam pit below or equal as we have seen before so we can change it. Teoh jump! It's not be no or equal The up was it for so any still the same result. Say more now to see the second example. So we're going to compare be here with the age if the others below them The age the world one contained the body one in Amsterdam, for one contained the value zero Let's open a second over now here we go. This is the second program, so problem it's almost a sentence. You're different in Jambi. Below here you see Jambi below. Andi can also actually change a distraction to Jim if not about equal, and then we have the same tips off. The first program lets you know the third example you were going to compare to the cln ch. So it CNN is above or record that ch the bar one contained the body. One else, the bar one content zero. So it's open. I work third program. So as you see here, jumping up over equal so everything is the same the only difference in the branch instruction. So here we put gender about over equal, as you see here. So if it's required to move Teoh destruction above or equal, we're going to put the bunny one in 41 Also get also change it today about its form, and we could jam if not below example Now we will compare the air with the age. The early is better or equal more. One has the value One else. Marwan contain the value zero. I don't see the forties uncle and here we have Jambi below or equal. So you compare the only the age general below recall and then the same thing with the other programs as we can also change ended blower quarts you jam. If lots of both the last program, we're going to compare air with a H if a lease about in a the world One contains the body one if a all is below the H one contained the body to else. If it's 1/4 11 contained the value three. So we open our program. So seven in a on six in a conquer air with age. If l is above an age, we jumped you the actionable which we're going to put one toe in for one else. If l is Bill Oden age, we jumped you below which we're going to put two in the variable one. So if it motorboat when it must be low so it's going to be equal We moved to the next instruction. If you move for 13 so three in the 41 and they would jump to the end of the program. So that's going over this and thank you and see you in the next lesson 39. 39-The branching -Part III (2): hot over one. In this lesson, we will see depression. Instructions of the comparison with sign it fun use. So the values that except the positive and the negative sign. That means that these instructions are actually the same instructions within science values . The only difference is in the inside it and the sign it. So the older instructions we use them in the inside and values and these instructions. We use them into science values. So the same examples the same work and everything is the same. The only difference is in the instruction for example, G. Grazer or jam. If it's greater, we have it. It's on its values. The same instruction Ys g a jam everything both or, for example, J g e J E. We have inside five years, Jim. If I bow for equal and then here we have jam if lower and he is I in 40 years, we have j b. So jammed if it below the last one is J l e Jeff. If it lower or equal in the inside of bodies we have J B Jim, if it below or equal. So you see everything is the same. The only difference in the sentence. J e It actually doesn't change. So we have J E in the sign for use and J e in the inside and fun use. Also, we have here Jay Z, which is Jeb if it zero under the same thing in the inside values aswell as we have the opposite off the instruction J and E So, Jim, if not equal and actually these instructions, they're equal. Teoh Another instructions, for example, Jam ever greater at the same thing with Jim, if not low for equal Jeff, If it's greater or equal, it is sent in with Jim. If not low Jim if it low. But the same thing with Jeb, if not greater or equal I for jam if it lower or equal, had the same thing with Gent. If not Lawrence, sir. So this is everything. I wish everything was clear. So you in the next lesson 40. 40-The branching instructions in the signed numbers -example: alone. What country? This lesson and this lesson. We're going to see an example off the precious instructions in the science but use So here we have moved air fire and then we have moved the l minus steel. We're going to compare air with BL If l is greater than the Are we going to jam two grades in great remove one in the register deal and if I am, is not greater than the air, so it lower or equal. So we went to our school and we have to put zero in the registered there and then we jump Teoh the end of the program. So that's running this program and see you. It's gonna happen from the registers on you compared air with bl and hear the results. Actually, air is greater than BSO, so we will jump to a great instruction. So as you see here we jobs to a great and the one interview Sergio the change or example. So for example, we put minus five in this example. Actually, we're going to jam to lower equal so comparing and with pl as we know, jam too great. So we move to the next instruction, gentle flower recall. And here we gentle lower level, as you see here. So move zero Judea. I then gem to the end of the program. So to give the last example and we put minus to you in order to have resolved as a call. So comparing am with beer and there is autistic also were jumped, you know, recall. So move zero to reduce a deal and champ to the end of the program. So I think that's what's easy. Thank you. And see you in the next list. 41. 41-Using the branching instructions with PF -example: I know everyone in this lesson. We're going to see another example of the branching instructions. So we're going to see how to use the parity flag, etcetera. So, as we said before the battle flag is raised when the occurance of the number one in the Breiner system is an even on you. So if it old value, nothing is gonna happen. Here we have. In this example we have moved four and we increments, they register a l and then we just the parity flag. So let's check, for example, the body five because we have four and increments for his five. So as we see here, the Volume five have the arguments. But number one is an even number because it's repeated twice. So that means that parity flag will be raised. So we would jam Teoh the pair instruction and in the instruction we have moved the air wants you were going to save one in their geezer, the l so does immediate that and see if true art percent of you have moved a f four. We sing us them the increment a l and then we just the parity flag he's raised. So we jammed to the pair instruction and the fair instruction we had moved there one so safe one in the desert, the L and then the end of the program. Now the change our example in order to get a north for you try with the value seven and thank you meant it will be eight. So you want to check eight? We see that it's not value, so it's wrong or program and see what we have. We text the person, flag it, not wrist. So we moved in Next instruction, which you have moved the l zero Wi said zero in the d l and we jam to the end of the program. So here's our program example and easy. And actually, we have the Northern Branch instructions Is the same off this one GP. So in the same off GP as we have also the opposite instruction which is GPO or G N P or jam , if not charity. So check your program with this instruction. And here the condition is verify. So support to Jan to the pair instruction because we have the number eight is notes on uneven body. You so yeah, as you see here we, Jim Teoh the instruction pair and move one to the air on the end of the program. This instruction cheese GMP is actually the same thing is G p o. So gm PNG bor this handy in and it's up to you to use wherever you want. So this is the answer. You on the next list. 42. 42-Data types: chars: Hello, everyone. And welcome to this lesson and this destiny. We're going to see another type off on information, which is the character. So what is the culture? The country is actually a group off. Example. English letters. Lower case in the upper case, the numbers from zero to line. We have Dunder school with a question mark. Exclamation mark the column camera, etcetera. Now how can we define valuable as character type? So how can you define the character variable? So, first, did you write the name of that character of, for example, right here, char and then write different bite here always should write different parts that cannot write defined world or any announced always different bite and the counter variable and then right our character in the first hour character should be writing between two single quote. So, for example, writes ah, a long case a uppercase or can write to common, for example, Question mark, for example, unacceptable, which would notice that right in the number one in this phone is not actually the same. That's writing it in this, it for me also, For example, writing the question mark in this form is not also in the same with this for as we can also stock the character of Are You in Your juicer? For example? Let's say they're just Ariel So it's right. Move a l and they were right. The culture, for example one. And as we said, writing the character, one in this form is not actually the same in this form. So Noah writing is in the country case. Let's eliminate it and see So as you see here, the value in the A X is 31. Want to change it? And right? Ah, number one in the other form the value and they're just a X is one. So it is not the same. How can we represent the characters? Actually, we can represent them by table. That's called asking table. So kick on the S. Kiko's and we get this table. So this table contained two columns the the right column and the left column in the rascal known we had different characters we have or the characters that we need. For example, here we have the country warm and always noticed that this is the character one and know the number one. So not the same. We have, for example, K as upper case and we have or the other cultures. And in the left side we have the inside of members. We have the inside of numbers from 0 to 255 so the stable contains assigned numbers and the character off each son number. For example, we have the value 49 its record to the counter one. We have also 54. It's referred to the character sex. We have also, uh, also, for example, 84. It referred to the upper case of the letter T on This is it. I want to see the values on the exactly similar system will just have to play. It wants, as you see here. And if you want to go back to the decimal system or click once again now, the question is white and sided numbers. If you remember, we said that all the informations are stuck in the memory of ones and zeros. The second thing is this information or these ones and zeros has no meaning without their presentation base. For example, this monetary value it means minus Stan in the sign and values and the dismal science values and it also means 246 and the inside and phone use faucets means division operation in the Ask HR. So what is happening exactly? When we define, for example, this variable charter as a defend bite, and we put the question mark initial value. The processor is going to look for this character and the ask a table in the room memory so it will keep looking for this character. So when the processor find the question mark, we'll take the inside and value that's refer to this character, which we have here. The question mark. The next day we convert this value to the boundary system and then stock it in the viable. So it like that. So it's like writing 63 the inside it values. And then we'll take this value and reparative to the character, to the car, to the char variable in the memory. So that's what happened exactly in the processor, and this is a Russian between the inside number and the Carter. Also, for example, if we have the character one energy surveil us, the processor was going to dio. The character would look in the ask a table for the character One. So So here we have the number 49 will take this number and converted to the binder system. And in the end would take this value and refer to the register A Oh, it was only in our this and thank you. See you in the next year. 43. 43-How to print a char in the DOS screen: Hello, everyone. And welcome to this. Listen. And this. Listen, we're going to see how it prints a character in the does this operation it actually pays on the interruption operation. What is interruption? Operation is to interrupt the program to do something. In our case here, we're going to interrupt the program in order to print a character. Also, we're going to the girls more about the relation between the sign it for years and the characters printing a character. It actually based on three steps. The first step is to move to to the register A h and two is actually a court. Terrorists were going Teoh figure out more about the cold services in the next lesson, But in this lesson, we're going to see the Branton service and they have the code service here is to and the next step we will move to the l. What? You want to print Example Here. We want Prince the character one. And in the third step, right? And I anti 21 age. It's interruption. 21 age 21. Edge is the code off interruption. So click on immune it single step and single steps. And so we have a screen off the DOS and here we have the guard through our and there is action. Little wager prints the cultures. And this way we're going to write the inside of number off the character. That's we want to Prince. So, for example, we have the card through one. We go to escape coats, we have the capture. One has 49 us and sign it number. So we write 49 in the register, dear, if you emulated with single steps here we see the character one. So that's all in order, sir. And thank you and see you in the next list. 44. 44-How to read a char from the keyboard: I know everyone and welcome to this lesson and it's Listen, we're going to see another service from service that over by the dose, we're going to see how to enter character from the cable. This operation. It's actually based on two steps. The first step, we move one to the register a h. So we have the court service one and then we have interruption to anyone. Age click on emulate. Here is the eminent your screen and the number one cause you see so we see 31 in the region survey eggs. That's right that you want in the converter So right that you want to be except they see more and we find in the SK char the character one. So as we have entered before, let's run a little example. So let's ride, for example, that is repay uppercase. And here we have 41 in the ridges e r a. L. If we check is so writes what you want inject dizzy more And here we have a uppercase into esque HR, let's write Also another example now. So, uh, single step and that's right. Be lower case, for example. Yeah, 62. If you check its And here we have be lower case. First, the due rights Want energy survey age and then right and 21 age. So the contacted us. We will Entrant will be interest you, sir. A l So this is the end. Thank you. And see you in the next list. 45. 45-The DOS services -example: Hello, everyone. And welcome to this lesson and this lesson. We are going to see a practical example about the services of the doors. His example. We're going to ask from the user to injure a character. And then we're going to print this culture. So for city, we have moved a H one, the one with the court service off entering a character from the keyboard and then interruption to anyone age. And then we're going Teoh a brand this culture so right move! Age to do. It's for the court service off Branton Onda. Then you have moved de l air wide because we said that going watch prince anything. We should put it on the allergies. Er so move what we want to print to the register, dear. And then we have interruption to anyone age the restaurant program and see the result. And here, as you see, regards the letter aid as you have entered and the aid as it was printed. And here we see this message program has returned control to the operating system. So why we got this message So it goes off this instruction. So after dealing with the DOS we it would be better actually to write this instruction. So after, for example, printing or reading, it would be better. Teoh, Right? Move a age, foresee age and then interruption 21 age in order to leave the dust and go back to the operating system. So this is all in our lesson. Thank you. And see you in the next list. 46. 46-Operations on the chars: I know everyone and this lesson. We're going to see some operations on the characters before that. We should know that says the characters are represented by the sign it values. So we have all the operations that we can use them on the science values. We could also use them and the characters as we can also use the branch in operations as jam pit below or jam if above etcetera. And this example, we're going to move the ill opera case, the letter A. And then we are 12 digits a deal. So actually a in a table s key, it's referred to the number of 65. If you aren't one, it will be 66 which is a reverend to be uppercase. So then we're going to print the results on the door screen. So move to a edge and then interruption 21 h as you mean it does and see. So as you see here, the upper cases upwards on the screen. Now we're going to see a very beer, for example. It's how to convert from the upper case to the lower case. Here we see that the upper case letters it starting with the 65 and its end in the 90 and we have the lower case letters salt with 97 it's anti in 122. So how can we converts from the upper case to the lower case? We can notice the difference between them is 32. So, for example, if we 32 to 65 we won't have a 97 so 65 for the upper case. If we add the 32 year we will have Nikes happened, which is for the lower case A on the same thing. For example, be we have in the upper case 66. If at the TT will have 98 which is the left will be lower case. Let's write this example. So we have a uppercase and we add 32 on a dissenting 20 age and exactly Seymour System 32. But you emanated and here a lower keys. This should examples So X upper case, for example. And here we have It's in our case now. How can we convert from the lower case to the upper case? So the idea is is not to add 32 its reception rocks 32 from the lower case. So, for example, have the our case. We subtract 32 and here we have the opera case. So this is the end. I wish everything was clear. Thank you. And see you in the next list. 47. 47-From the uppercase to the lowercase: Hello, everyone, and welcome to this lesson. And this isn't going to make a program that ask from the user to Andrew Uppercase letter and then we will convert to lower case letter. Firstly, we defined user char as a variable with bite size and with a known value and then right, move a x data and then move the S a X. So in the first tape, going to read a character so writes move a H one and then interruption to anyone age and then we move The result temporally register bl in order to use it later, the next step, we verify if it's an opera case culture or not. So we used to branch in conditions because we have here the upper case letters are starting from 65 to 90 so we would compare if it's below 65. We jam to the end of the program on the same thing if it's above 90. So this is mean that it's not upper case. So we also were jammed to the end of the program to the corrupted. But we have entered it should be between 65 90 just mean uppercase character. So if not below 65 not about 90. We move to the next step and this is mean we have an uppercase letter. So in the next step, we will print a new line, and that needs actually to inside it numbers in the s key Coach. The 1st 1 is 10 for the new line, and the 2nd 1 is 13 for moving to the beginning off the line. So we right move age to for printing court service. And then we moved 10 to deal for the new line instruction and then interruptions When you want age, we brains in your life. And then we moved there 10 to the l in order to go to the beginning off the line and attraction to anyone age for printing. It's. And in the end, we're going to convert the letter to the lower case and then save it. And then we print it. And you said the results in the valuable user Carter that we have defined before. So move the l A. The l and we have NBL the uppercase letter that we have entered before. So we're going to use it now and then we add 32 to the day l to convert the letter to the upper case or we add 20 age and exodus him. Also, let's try in this time 20 age and then remove the L to their body board user Charles. And in the end, we have interruptions when you want H for the printing service because we have entered before the court service to so we don't have to repeat the game. So it's communicator program? No. So let's try, for example, the ledger, the upper case. And here we see the lower case, the change of example. So what? You may days again the try, for example, the letter k uppercase. And here we see the letter K lower case. So this is the end. Thank you. And see in the next this 48. 48-Read a digit -example: Hello, everyone. And welcome to this. Listen, and this isn't We're going to see a program that asked from the user's Johansson number, and we're actually the numbers from 0 to 9. It the same numbers that we have in the characters. So we cannot, for example, writes at Dan or something like that. So in this example, we're going to ask the user chancellor number, and the number of us we enter will appear in the A L So, for example, we write the number two and here we see a 32 in the air. But the problem is, I don't want to appear signed numbers off the character that I want. So I don't wanna have a 2 to 1 day l I want to have the same number I answered. So I want to see two in the A L. So this is our example. Personally, we have moved h one, wanted the court service and learn about your options when you want H and then we're going to compare a with the number with volume 48 because here we have the number starting in the 48. So if we have 47 46 ounces mean we don't have a number. So this is mean that the number that I answer should not be below then 48 and we have the center for 57. So the number should be above then 57 because our numbers and in in the 57. So it should be between 48 57. And then we have subtract am 48. Why we did that? Because when we have a number, members are from 48 to 57. So, for example, we have 48. If we subtract 48 we will have zero. So it does not. So zero would be with zero and one with one. And this is it. So humiliates program. We answer, for example Zero. And here was he zero in the ale. Try another example. So let's try with number two. And here was he do in the oil literally? Yeah, for example, nine now. So here the number nine. And here we see a line in the air. So this is the end of a program. Thank you and see you the next 49. 49-How to print a message in the DOS screen: Hello, everyone. And welcome to this lesson and the lesson we're going to see out your prints, a message and the British lessons. We saw how to print a character, and now we're going to see how to prince group of characters which is formed a message. So we're going to dry the famous example. Hollow words for his evolution define a valuable off the message that we want to print. And here we have the body bore a message MSG So we defined this valuable as a bite and t