Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate nonlocal games: GHZ game classical #1783

Conversation

ggridin
Copy link
Contributor

@ggridin ggridin commented Jul 24, 2024

The link to the issue: #1596

This pull request is covering

  1. GHZ classic tasks 1.1
  2. GHZ task 1.2 (random) is dropped. Task 1.3 is expanded into implementation of 3 strategies (Alice, Bob and Charlie)
    This approach allow to create more complicated output like [true, false, false] or [r, DrawRandomBool(0.8), not t]
  3. GHZ classic task 1.4

@ggridin
Copy link
Contributor Author

ggridin commented Jul 29, 2024

Questions for this PR:

  1. The mentioned winning strategies in solution.md are [true, true, true] and [true, false, false]
    There are also [true, true, z], [false, y, z] and more. Should we ask student an optional question to find more winning strategies?

Testing done:

Build "python ./build.py" is successful
Placeholder cases are syntactically correct but failing verifications.
Solutions are successful.
Some other failure scenarios were tested manually:
Exercise "Classical Strategy":

  • [true, true, true]
  • [true, false, false]
  • [true, true, z]
  • [false, y, z]
    and combinations of them. Negative scenarios were tested also.
    Exercise "GHZ Classical Game":
  • return [a, b, c]
  • return [true, true, true] (without use of strategies)
  • return [a, b, true]
  • return [a, c, b]
    and combinations of them. Negative scenarios were tested also.

GHZ classical game
GHZ classical strategy
GHZ game
GHZ win condition

Copy link
Member

@tcNickolas tcNickolas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! I like the tweak on the second task to allow everybody to use a different classical strategy, since we can do it easily with the new infrastructure!

I left some cosmetic comments, nothing major.

Thank you!

katas/content/nonlocal_games/ghz_win_condition/Solution.qs Outdated Show resolved Hide resolved
katas/content/nonlocal_games/ghz_win_condition/solution.md Outdated Show resolved Hide resolved
katas/content/nonlocal_games/index.md Outdated Show resolved Hide resolved
katas/content/nonlocal_games/ghz_classical_game/index.md Outdated Show resolved Hide resolved
katas/content/nonlocal_games/ghz_classical_game/index.md Outdated Show resolved Hide resolved
katas/content/nonlocal_games/ghz_classical_game/index.md Outdated Show resolved Hide resolved
@ggridin ggridin requested a review from tcNickolas August 7, 2024 22:05
Copy link
Member

@tcNickolas tcNickolas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! (Apologies for the delay reviewing, trying to wrap as many things up as I can before disappearing until next week...)

Thank you!!

@ScottCarda-MS
Copy link
Contributor

This looks great! Thanks for putting the time in to get this done!

@tcNickolas tcNickolas changed the title Migrate nonlocal games 1596 task-2 GHZ game classical Migrate nonlocal games: GHZ game classical Aug 8, 2024
@tcNickolas tcNickolas added this pull request to the merge queue Aug 8, 2024
Merged via the queue into microsoft:main with commit 7ae7a6f Aug 8, 2024
19 checks passed
@ggridin ggridin deleted the MigrateNonlocalGames-1596-task2-GHZ-classical branch August 9, 2024 03:52
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.

3 participants