Skip to main content
0 votes
1 answer
38 views

I'm trying to build a pushdown automaton (PDA) in JFLAP that accepts the following language: L={0 1^N 2^P 3^R 4^S ∣ N,P,R,S>0, and N+P<R+S} with input alphabet Σ={0,1,2,3,4}Σ={0,1,2,3,4} This ...
Sebas's user avatar
  • 1
3 votes
1 answer
189 views

I'm building a compiler for a custom programming language called FLOW, written in C. After lexical analysis using a DFA, I want to implement a PDA (Pushdown Automaton) to validate the syntax of the ...
AdirMor's user avatar
  • 35
1 vote
1 answer
2k views

I drew PDA diagram for this language but it still does not work. Can some please help me? My PDA accepts 'bc' which it should not. I have no idea to control the b and c of the language. My scala code ...
Youngheon Jeong's user avatar
0 votes
1 answer
230 views

Just learned about DPDA's on my Theory of computation class. Professor gave us a semester task to create a deterministic pushdown automaton state diagram that is able to accept all strings multiples ...
Santiago Lemus Vallejo's user avatar
0 votes
1 answer
232 views

We have a language W over the alphabet {a,b,c,d,e,f,g} that is defined by, starting with : <A> ::= <A> <Z> 'c' | <A> <X> 'd' | 'b' <Z> ::= <Y'> 'e' <Z> |...
phuck's user avatar
  • 23
2 votes
0 answers
225 views

I have been asked to construct a NPDA that accepts the following language L = {anb2n : n ≥ 1}. I have completed the written assignment portion and after testing it thoroughly i am sure that my NPDA is ...
hello_people's user avatar
0 votes
1 answer
3k views

I am currently enrolled in the undergraduate version of Theory of Computation at my university and we are discussing Pushdown Automata, Turing Machines, and the Church-Turing Thesis. In our homework ...
anthonyvn's user avatar
2 votes
2 answers
423 views

I'm working on define to a new language with lex and yacc. The lexer works fine but parser doesn't. I thought the problem is the grammar is not recognizing tokens but after lots of researches and ...
user avatar
0 votes
2 answers
378 views

I'm wondering how could I design a pushdown automaton for this specific language. I can't solve this.. L2 = { u ∈ {a, b}∗ : 3 ∗ |u|a = 2 ∗ |u|b + 1 } So the number of 'a's multiplied by 3 is equals to ...
shlyy's user avatar
  • 63
0 votes
2 answers
3k views

I know how to solve for m<n but I'm struggling to understand the logic for m>n. In m<n we push all a's in the stack and when we get b we popped out one a, when the input ends with a stack ...
Aayushi Vaghasiya's user avatar
0 votes
1 answer
261 views

I'm a little confused about PDA's and how to define the tuple. I have the language L = { 0^n1^n | n >= 0 } and I know that PDA's are six tuple with Q, sigma, gamma, delta, q0, and F. I know how to ...
anonymous's user avatar
0 votes
1 answer
411 views

How to construct a pushdown automata for L= { w ∈ {a, b}* | w does not equal xx^R for some x ∈ {a, b}* }
Rajeev Ranjan Pan's user avatar
0 votes
2 answers
2k views

The solution says for every 'a' you read, push 2 a's into the stack . Finally when you encounter 'b' , pop an 'a'. But won't this give the output as a^n b^n? For example: Input = aabbbb On reading the ...
Mihir Sanjay's user avatar
0 votes
1 answer
609 views

Starting with the letter b and the number of the letters b is 1 more than the number of the letters a a PDA that accepts language It confused me a lot. Can anyone explain how it's done?
Carl Jackson's user avatar
4 votes
2 answers
5k views

Can someone help me design PDA for {a^n b^m | n<=m<=2n}. Can you please design one with explanation.
RJ Naskar's user avatar

15 30 50 per page
1
2 3 4 5
13