Suppose that your grades are kept in a file with the following format: The file contains one or more student records. Each student record has one student\'s name, then their ID number, then zero or more grades, separated by commas. Each grade is an integer value followed by zero or more stars (to represent the number of days late). This being a course on compilers, the TAs decided to write a parser to read the grades, making it easy to summarize. Here\'s a CFG for the grade file format that they came up with. The grade file is updated after every assignment is graded. file rightarrow record tail tail rightarrow file | epsilon record rightarrow NAME IDNUM optGrades optGrades rightarrow grades | epsilon grades rightarrow oneGrade | oneGrade COMMA grades oneGrade rightarrow INTLIT optLate optLate stars | epsilon stars rightarrow STAR | stars STAR a. Although the grade file CFG given above is not LL(1), some correct inputs can be parsed by a predictive parser. This is because those inputs never cause the parser to look at a table entry that contains two or more CFG rules. However, the TAs ran into problems parsing this file at some point in the course because the CFG is not LL(1). i. Give the shortest such grade file input (as a sequence of tokens, ending with EOF). ii. Draw the parse tree that the parser would build for the input you gave for Part (i). (Do not include the EOF token in the parse tree.) b. What is the earliest point in the course at which the parser broke? (i.e., a sequence of tokens that is a prefix of a valid input, but for which the parser would not know how to continue to build the parse tree top-down because it looks at a table entry that contains two or more CFG rules)? To answer this question, give all of the following: i. The sequence of tokens (a prefix of a valid input). ii. The (partial) parse tree that the predictive parser would have built before being stumped. iii. The CFG rules that the predictive parser can\'t choose between to continue to grow the parse tree. c. One problem with the grade file CFG is that it has not been left factored. Find the CFG rules with a common prefix and transform them by doing left factoring. d. Another problem with the grade file CFG is that is has immediate left recursion. Find the CFG rules that cause this and transform them to remove the left recursion.
Encrypt the plaintext blocks using single DES with key K1.
Now decrypt the output of step 1 the use of single DES with key K2.
finally, encrypt the output of step 2 the use of single DES with key K3.
The output of step 3 is the ciphertext.
Decryption of a ciphertext is a reverse technique. consumer first decrypt the use of K3, then encrypt with K2, and in the end decrypt with K1.
because of this layout of Triple DES as an encrypt–decrypt–encrypt system, it\'s miles feasible to apply a 3TDES (hardware) implementation for single DES by means of placing K1, K2, and K3 to be the same fee. This gives backwards compatibility with DES.
second version of Triple DES (2TDES) is identical to 3TDES besides that K3is replaced by using K1. In other words, person encrypt plaintext blocks with key K1, then decrypt with key K2, and subsequently encrypt with K1 again. consequently, 2TDES has a key length of 112 bits.
Triple DES structures are appreciably more comfortable than single DES, however those are genuinely a far slower method than encryption using unmarried DES.