Skip to content

new solution for the hard variant#39

Closed
ShalevWen wants to merge 1 commit into
SheafificationOfG:mainfrom
ShalevWen:new-hard-record
Closed

new solution for the hard variant#39
ShalevWen wants to merge 1 commit into
SheafificationOfG:mainfrom
ShalevWen:new-hard-record

Conversation

@ShalevWen

Copy link
Copy Markdown
Contributor

No description provided.

@github-actions

Copy link
Copy Markdown

Summary

Difficulty Questions Complexity Comments
hard 4.74383 808 Engineer question limit: 2

@GSheaf GSheaf closed this in 5499c75 Dec 23, 2025
@GSheaf GSheaf reopened this Dec 23, 2025

@GSheaf GSheaf left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Whoops, didn't mean to close this outright.

I don't intend to merge this submission as-is, but that's quite the compression!
Does decompressing your string have the same improved average?

Comment thread submissions/habub.py
# This is an optimized version of ganitsu_optim.

# I don't even know how I did it, but in the process of compressing the data
# I also improved the questions average

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

That is very interesting indeed... I wonder what changed.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

i did change the actual bytes where it helped shortening the string. for example:

>>> repr("\ude84")
"'\\ude84'"
>>> repr("\uce84")
"'캄'"
>>> 

it makes sense that some of these changes would be possible without changing the logic, since you could add or remove a question if you know the response is no (P or False = P).
it is interesting though that somehow i managed to change the actual logic in a way that doesn't break it.

on that note, I would remove the part that gives spaces in strings for free,
i manged to improve the complexity by about 290 just by replacing unicode characters with spaces

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I don't think I have to manually check every edge case where people can hack the efficiency score; I'll just arbitrate with my eyes.

But thanks for the submission!

@GSheaf GSheaf closed this Dec 23, 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