← Back to topics
Topic

stream flushing and on-line algorithms

s
syntax_error
i was wondering if there is a way to test if an algorithm is on-line here in z-trening tasks. for example, if the input consists of queries, and the problem asks for some data to be printed for some queries, i'd like the program to answer the current query before he gets the next one. i've seen this being done by waiting for the output stream to be flushed before giving the next query. is this possible here?