Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3960112
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T02:48:52+00:00 2026-05-20T02:48:52+00:00

First of all I do not know if this is the correct translation for

  • 0

First of all I do not know if this is the correct translation for what I am asking.

In one of my courses we just stared learning about regular expressions, formal languages and so on.

Alphabet {1,0,S,R}
Terminals {1,0}
Rules:

S ::= 0
S ::= 1
S ::= 1R
R ::= 1R
R ::= 0R
R ::= 1
R ::= 0

In this case let say that I start with the 1R, then I could keep on going with either 1R or 0R.

If I start with 1R, then just a 1….then the sentence(in this case its binary numbers) is complete right? Because I can’t “append” something afterwards, say 1R then I choose 1 and then I choose 1R again?

Thanks in advance, and please retag/move post if its uncorrect.


ADDED:

0  at rule S ::= 0  
1  with S ::= 1  
10 with S ::= 1R, so R ::= 0

How to generate 1100110?

This is not homework, it is an example/question from the powerpoint. I do not get how that is done.

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T02:48:53+00:00Added an answer on May 20, 2026 at 2:48 am

    What you have there is a regular language, defined using a context free grammar. A regular expression that defines the same language is (0)U(1{0,1}*). In plain english, the regular language contains all strings of 0s and 1s that start with 1, and the string 0.

    A context free grammar starts with some initial non-terminal symbol, in this case it appears to be S. You then can replace any non-terminal symbols with a string of symbols according to the production rules listed. It is “done” when the string contains no non-terminal symbols.

    In your example, you can only “choose 1R” if there is currently an S or an R in the string to replace. As it happens with this grammar, the first time you replace R with 1, you no longer have any non-terminals to replace, and that production of a string is finished.

    Edit: Here is a trace of the production of 1100110.

    S  
    1R         via S ::= 1R
    11R        via R ::= 1R
    110R       via R ::= 0R
    1100R      via R ::= 0R
    11001R     via R ::= 1R
    110011R    via R ::= 1R
    1100110    via R ::= 0
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

First of all, I just started PHP. I know my methods might not be
First of all, I know there are a lot of questions about this topic.
First of all i don't know whether the title is relevant or not (please
First of all, I know that UDP is not a reliable protocol but I
first of all: this is not the same as this . The ModelBackend has
First of all I'm not sure this is even possible, however I need to
First of all I am not a designer. so this question is may be
First of all: This question is not directly programming related. However, the problem only
Thanks a lot for all the beautiful answers! Cannot mark just one as correct
I have just started learning XNA. This is my first program that I am

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.