M
M
Melmoth2015-01-19 01:46:40
TeX
Melmoth, 2015-01-19 01:46:40

How to automatically create a collection of tasks from separate files with conditions, with a numbered list of answers and solutions at the end?

The essence of the problem is as follows:
There is a certain set of tasks, say, in mathematics, each of which consists of 3 components: "Condition", "Answer" and "Decision". For each task, the information is stored together in a separate TeX file. (Here, however, options are possible: the possibility of organizing them into a certain database is not ruled out, but with the condition that it is convenient to add and edit them using LaTeX, shuffle, split into parts).
It is necessary to implement a function of the \zadacha{nazvanie_zadachi.tex} type, which takes the "Condition" section from the nazvanie_zadachi.tex file, inserts it at the given place in the document, numbers it according to the chapter/section number of the document, and formats it properly (for example, writes "Task No...." and further condition). Also, at the end of the document, the \answer and \resheniya commands are written, each of which, under the corresponding numbers, imports the "Answer" and "Solution" sections of all the tasks listed in the document.
In general, this is very similar to adding links from a database and generating a bibliography. But I still have little idea how to implement it myself. Perhaps something similar already exists, but it is unlikely in such a form that it can be used without alterations. Perhaps someone can explain (at least in general terms) how such things work in TeX, or provide links to literature where all this is described in detail. In general, I will be glad to any help and tips.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
krypt3r, 2015-01-20
@krypt3r

Try to look here

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question