0% found this document useful (0 votes)
53 views2 pages

SL-V Assignment Questions

The document lists 12 programming problems related to compiler design techniques: (1) implement Pass-I of a two-pass assembler, (2) implement Pass-II to output the results of Pass-I, (3) implement a lexical analyzer for a C subset, (4) implement a recursive descent parser, (5) implement a calculator using LEX and YACC, (6) generate intermediate code using LEX and YACC for control flow statements, (7) find max and min array elements using divide-and-conquer, (8) solve an optimal storage problem using greedy approach, (9) implement Bellman-Ford algorithm using dynamic programming, (10) solve the travelling salesman problem using

Uploaded by

jagdish750
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
53 views2 pages

SL-V Assignment Questions

The document lists 12 programming problems related to compiler design techniques: (1) implement Pass-I of a two-pass assembler, (2) implement Pass-II to output the results of Pass-I, (3) implement a lexical analyzer for a C subset, (4) implement a recursive descent parser, (5) implement a calculator using LEX and YACC, (6) generate intermediate code using LEX and YACC for control flow statements, (7) find max and min array elements using divide-and-conquer, (8) solve an optimal storage problem using greedy approach, (9) implement Bellman-Ford algorithm using dynamic programming, (10) solve the travelling salesman problem using

Uploaded by

jagdish750
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

1.

Write a program to implement Pass-I of Two-pass assembler for Symbols and

Literal processing considering following cases

1. Forward references
2. DS and DC statement
3. START, EQU, LTORG, END.
4. Error handling: symbol used but not defined, invalid instruction/register etc.
START 200
MOVER AREG, =’5’
MOVEM AREG, A
LOOP MOVER CREG, B
ADD CREG, =’1’
LTORG
ORIGIN LOOP+2
MULT CREG, B
STOP
A DS 2
B DS 2
END

2. Write a program to implement Pass-II of Two-pass assembler for output of Q.1

3. Write a program to implement Lexical Analyzer for subset of C.

4. Write a program to implement a Recursive Descent Parser.

E→E+E |E-E|E*E|E/E|(E)|digit

5. Write a program to implement calculator using LEX and YACC.

6. Write a program for Intermediate code generation using LEX &YACC for
Control Flow statement ( Either While loop or Switch case)
7. Write a program to find Maximum and Minimum element in an array using

Divide and Conquer strategy and verify the time complexity.

8. Write a program to solve optimal storage on tapes problem using Greedy

approach.
9. Write a program to implement Bellman-Ford Algorithm using Dynamic

Programming and verify the time complexity.

10. Write a program to solve the travelling salesman problem and to print the path

and the cost using Dynamic Programming.

11. Write a recursive program to find the solution of placing n queens on chessboard

so that no two queens attack each other using Backtracking.

12. Write a program to solve the travelling salesman problem and to print the path

and the cost using Branch and Bound.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy