Git Product home page Git Product logo

Comments (11)

mzuenni avatar mzuenni commented on June 22, 2024 1

Ah, well in that case I would prefer \sample{<filebasename>} and maybe an additional \allSamples.

from problemtools.

ghamerly avatar ghamerly commented on June 22, 2024

The problem format has support for annotations (see http://problemarchive.org/wiki/index.php/Problem_Format#Annotations), but none of them seem to address exactly what you're looking for (i.e. text that makes it into the problem statement).

It does seem that if a sample input has a .desc file, that could conceivably be put in the problem description (since the case, being a sample, is known). However, the .desc file is explicitly described as privileged (judge-only) information in the problem format. I would argue that nothing about the sample cases are privileged. So maybe this could be used for what you are suggesting.

from problemtools.

godmar avatar godmar commented on June 22, 2024

Agreed. One issue to note is whether LaTeX is allowed or not in the file, perhaps could have two suffixes .desc.txt and .desc.tex or similar.

from problemtools.

eldering avatar eldering commented on June 22, 2024

I'd prefer to keep the already defined .desc and add an optional .desc.tex. That makes it simpler for systems that don't support LaTeX (e.g. Kattis or DOMjudge when importing a problem) to know which file to look for, and doesn't change the standard, only extend it.

from problemtools.

austrin avatar austrin commented on June 22, 2024

Agree that it should be a new file. Not sure if desc.tex is the right suffix. Usually it will be an explanation of a test case, rather than a description. But .explanation.tex feels a bit long-winded...

from problemtools.

niemela avatar niemela commented on June 22, 2024

@jsannemo @simonlindholm How do we handle this at PO? Do we just avoid it? Do we need a fix for this?

from problemtools.

simonlindholm avatar simonlindholm commented on June 22, 2024

We usually have a \section*{Sample explanations} at the bottom of the problem statement, saying things like "In the first sample, ...". I think it works fine, though it might encourage us write more sample explanations if it was a more integrated part of the problem format.

from problemtools.

RagnarGrootKoerkamp avatar RagnarGrootKoerkamp commented on June 22, 2024

@mzuenni

from problemtools.

mzuenni avatar mzuenni commented on June 22, 2024

At GCPC we added a command to problemset.cls whose content is typeset after the automatically included samples (I also implemented something similar for BAPCtools).
However, my preferred way to handle this would be a command like \includeSamplesHere which can be used at any point to typeset the samples (and if it is never called will automatically be executed at the end).

from problemtools.

RagnarGrootKoerkamp avatar RagnarGrootKoerkamp commented on June 22, 2024

@mzuenni note that this is specifically about interleaving samples with explanations, so that you could have

<sample 1>
<explanation 1>
<sample 2>
<explanation 2>
...

Currently I don't see a super nice way of doing this. Maybe we can add \sample1, \sample2, ... that can be used from problem.en.tex to render samples?

from problemtools.

jsannemo avatar jsannemo commented on June 22, 2024

This should at the very least support Markdown too.

Other than that I (unfortunately) think this is the best way out. At least I don't see a nicer way (the sample/1.explanation.tex I don't like: it's more important to put it together with the rest of the statement).

from problemtools.

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.