Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

Chipe1
Copy link
Contributor

@Chipe1 Chipe1 commented Jun 6, 2017

It is the inefficient implementation so I have commented out the test cases which takes 1 minute to run.
Also added constant_symbols() and its test.

@norvig
Copy link
Collaborator

norvig commented Jun 7, 2017

This looks good.
Can we have a simpler test that runs faster?
Also, I note that we define knowledge bases with

   map(expr, ['A', 
                'B', 
                'C', ...])

could we just do

  expr("""A, 
          B, 
          C, ...""")

and since expr calls eval, wouldn't this just return a tuple of sub-exprs?

@norvig norvig merged commit b14e21a into aimacode:master Jun 7, 2017
@Chipe1 Chipe1 deleted the fcask branch June 9, 2017 11:03
@Chipe1
Copy link
Contributor Author

Chipe1 commented Jun 9, 2017

I was unable to get the second format to work in multiple lines. eval throws SyntaxError due to the new line characters. I tried to use ''' inside """ but that didn't work either. I think it is better to leave it as it is. Using techniques to ignore the newline character would only make it harder to read.

dj5x5 pushed a commit to dj5x5/aima-python that referenced this pull request Jul 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants