Giter Club home page Giter Club logo

Comments (5)

laike9m avatar laike9m commented on May 30, 2024

Adding hint is something I've always considered, but I haven't thought of an ideal way to store hints.

Here are the requirements if we were to add this feature:

  • Hint should be optional for a challenge (i.e. it's perfectly fine that a challenge does not have hint(s))
  • Adding hint should be easy and add as little extra work as possible for contributors

In terms of implementation, I'm a bit hesitant to put it in question.py. Having to write ## End of your code ## is already very tedious (I can't remember it and have to copy&paste each time adding a new challenge), and ## HINT start ## makes things worse...

At this point I'm more leaning towards putting hints in a separate file. Maybe we can store it in a markdown hints.md so that it's easier to add (than write html). So it would look something like

# hints.md
HINT: Check out [Callable](https://docs.python.org/3/library/typing.html#annotating-callable-objects).

from python-type-challenges.

piglei avatar piglei commented on May 30, 2024

Having to put ## End of your code ## is already very tedious (I can't remember it and have to copy each time adding a new challenge), and ## HINT start ## makes things worse...

lol, yes, that would definitely make it harder to add new questions and make question.py a little too noisy. If we don't want to stick to using magic comments in question.py, introducing a new markdown file for storing hint messages would be better.

I would be happy to implement this feature.

from python-type-challenges.

laike9m avatar laike9m commented on May 30, 2024

Awesome, that would be of great help!

Another consideration is how to show hints on a challenge page. I think the only requirement is to not show it directly, maybe with a popup or something similar. I'll leave this to you to decide :)

from python-type-challenges.

piglei avatar piglei commented on May 30, 2024

Implemented in #71.

Screenshots:

image image

from python-type-challenges.

laike9m avatar laike9m commented on May 30, 2024

Closed, since most challenges have hints now. More will be added as time goes.

from python-type-challenges.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.