2020-01-21 06:35:58 +00:00
|
|
|
{% if submission.contest_or_none %}
|
|
|
|
{% set prefix_length = submission.contest_or_none.problem.output_prefix_override %}
|
|
|
|
{% else %}
|
|
|
|
{% set prefix_length = None %}
|
|
|
|
{% endif %}
|
|
|
|
{% set is_pretest = submission.is_pretested %}
|
|
|
|
|
|
|
|
{% if submission.status != 'IE' %}
|
|
|
|
{% if submission.status == 'QU' %}
|
|
|
|
<h4>{{ _('We are waiting for a suitable judge to process your submission...') }}</h4>
|
|
|
|
{% elif submission.status == 'P' %}
|
|
|
|
<h4>{{ _('Your submission is being processed...') }}</h4>
|
|
|
|
{% elif submission.status == 'CE' %}
|
2022-08-19 04:26:30 +00:00
|
|
|
<h3><i class="fa fa-exclamation-circle fa-fw"></i>{{ _('Compilation Error') }}</h3>
|
2020-01-21 06:35:58 +00:00
|
|
|
<pre>{{ submission.error|ansi2html }}</pre>
|
|
|
|
{% else %}
|
|
|
|
{% if submission.error %}
|
2022-08-19 04:26:30 +00:00
|
|
|
<h3><i class="fa fa-exclamation-triangle fa-fw"></i>{{ _('Compilation Warnings') }}</h3>
|
2020-01-21 06:35:58 +00:00
|
|
|
<pre>{{ submission.error|ansi2html }}</pre>
|
2020-03-17 06:11:03 +00:00
|
|
|
<hr><br>
|
2020-01-21 06:35:58 +00:00
|
|
|
{% endif %}
|
|
|
|
{% if is_pretest %}
|
2022-08-19 04:26:30 +00:00
|
|
|
<h3><i class="fa fa-check-square-o fa-fw"></i>{{ _('Pretest Execution Results') }}</h3>
|
2020-01-21 06:35:58 +00:00
|
|
|
{% else %}
|
2022-08-19 04:26:30 +00:00
|
|
|
<h3><i class="fa fa-check-square-o fa-fw"></i>{{ _('Execution Results') }}</h3>
|
2020-01-21 06:35:58 +00:00
|
|
|
{% endif %}
|
2021-05-26 17:10:19 +00:00
|
|
|
|
2022-08-23 04:30:41 +00:00
|
|
|
{% for batch in batches %}
|
|
|
|
<div style="margin-top: 0.5em;">
|
|
|
|
{% if batch.id %}
|
2022-11-22 04:05:35 +00:00
|
|
|
<b>{{ _('Batch ') }}#{{ batch.id }} ({{batch.points|floatformat}} / {{batch.total|floatformat}}): </b>
|
2022-08-23 04:30:41 +00:00
|
|
|
{% endif %}
|
|
|
|
{% for case in batch.cases %}
|
|
|
|
<span class="case-{{ case.status }} case-icons">
|
|
|
|
{% if case.status == 'AC' %}
|
|
|
|
<i id="icon-{{case.id}}" class="icofont-check-circled" title="{{ _('Case') }} #{{ loop.index }} - {{ case.status }}"></i>
|
|
|
|
{% elif case.status != 'SC' %}
|
|
|
|
<i id="icon-{{case.id}}" class="icofont-close-circled" title="{{ _('Case') }} #{{ loop.index }} - {{ case.status }}"></i>
|
|
|
|
{% endif %}
|
|
|
|
</span>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
|
|
|
{% endfor %}
|
|
|
|
<br>
|
|
|
|
|
2021-05-26 17:10:19 +00:00
|
|
|
<table class="testcases-table">
|
|
|
|
{% if submission.is_graded and submission.result != 'AB' %}
|
2020-03-17 06:11:03 +00:00
|
|
|
<thead>
|
2021-05-26 17:10:19 +00:00
|
|
|
<tr id="overall-row" class="case-row overall-result-{{submission.result}}">
|
|
|
|
<td><span class="col-title">{{_('Overall: ')}}</span>
|
2022-01-10 11:13:46 +00:00
|
|
|
{% if request.in_contest_mode and submission.contest_or_none %}
|
2021-05-26 17:10:19 +00:00
|
|
|
{% with contest=submission.contest_or_none %}
|
2022-02-21 01:03:13 +00:00
|
|
|
{{ _('%(points)s/%(total)s', points=contest.points|roundfloat(3),
|
|
|
|
total=contest.problem.points|floatformat(-1)) }}
|
2021-05-26 17:10:19 +00:00
|
|
|
{% endwith %}
|
|
|
|
{% else %}
|
|
|
|
{{ _('%(points)s/%(total)s', points=submission.points|roundfloat(3),
|
|
|
|
total=submission.problem.points|floatformat(-1)) }}
|
|
|
|
{% endif %}
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td><span class="case-{{submission.result}}">{{submission.long_status}}</span></td>
|
|
|
|
|
|
|
|
<td><span class="col-title">{{_('Point: ')}}</span>
|
|
|
|
{{ submission.case_points|floatformat(1) }}/{{ submission.case_total|floatformat(0) }}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td><span class="col-title">{{_('Time: ')}}</span>
|
|
|
|
{% if submission.result == "TLE" %}
|
|
|
|
<span>---</span>
|
|
|
|
{% else %}
|
|
|
|
<span title="{{ submission.time }}s">{{ (submission.time * 1000)|floatformat(0) }} ms</span>
|
|
|
|
{% endif %}
|
2020-03-17 06:11:03 +00:00
|
|
|
|
2021-05-26 17:10:19 +00:00
|
|
|
</td>
|
|
|
|
|
|
|
|
<td><span class="col-title">{{_('Memory: ')}}</span>{{ submission.memory|kbdetailformat }}</td>
|
|
|
|
</tr>
|
2020-03-17 06:11:03 +00:00
|
|
|
</thead>
|
2021-05-26 17:10:19 +00:00
|
|
|
{% endif %}
|
2020-03-17 06:11:03 +00:00
|
|
|
|
2021-05-26 17:10:19 +00:00
|
|
|
<tbody>
|
|
|
|
{% for batch in batches %}
|
|
|
|
{% if batch.id %}
|
|
|
|
{% set batch_AC = (batch.points == batch.total) %}
|
2022-12-18 09:31:31 +00:00
|
|
|
<tr class="case-row" class= "background-{{ 'd6e8f7' if batch.points == batch.total else 'bisque'}}">
|
2021-05-26 17:10:19 +00:00
|
|
|
<td>
|
2022-11-19 23:30:07 +00:00
|
|
|
<b>{{ _('Batch ') }}#{{ batch.id }}</b>
|
2021-05-26 17:10:19 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
{% if batch_AC %}
|
|
|
|
<span class="fa fa-check case-AC"></span>
|
|
|
|
{% else %}
|
|
|
|
<span class="fa fa-times case-WA"></span>
|
|
|
|
{% endif %}
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<span class="col-title">
|
|
|
|
{{_('Point')}}:
|
|
|
|
</span>
|
|
|
|
{{ _('%(points)s/%(total)s', points=batch.points|floatformat(1), total=batch.total|floatformat(0)) }}
|
|
|
|
</td>
|
|
|
|
<td></td>
|
|
|
|
<td></td>
|
|
|
|
</tr>
|
|
|
|
{% endif %}
|
2020-03-17 06:11:03 +00:00
|
|
|
{% for case in batch.cases %}
|
2020-01-21 06:35:58 +00:00
|
|
|
<tr id="{{ case.id }}" class="case-row toggle closed">
|
|
|
|
<td>
|
2021-06-17 06:49:09 +00:00
|
|
|
{%- if can_see_testcases -%}
|
2020-01-21 06:35:58 +00:00
|
|
|
<i class="fa fa-chevron-right fa-fw"></i>
|
|
|
|
{%- endif -%}
|
|
|
|
{%- if batch.id -%}
|
|
|
|
<b>{{ _('Case') }} #{{ loop.index }}:</b>
|
|
|
|
{%- elif is_pretest -%}
|
2021-05-26 17:10:19 +00:00
|
|
|
<b>{{ _('Pretest') }} #{{ loop.index }}:</b>
|
2020-01-21 06:35:58 +00:00
|
|
|
{%- else -%}
|
2021-05-26 17:10:19 +00:00
|
|
|
<b>{{ _('Test case') }} #{{ loop.index }}:</b>
|
2020-01-21 06:35:58 +00:00
|
|
|
{%- endif -%}
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
<span title="{{ case.long_status }}" class="case-{{ case.status }}">
|
2020-03-17 06:11:03 +00:00
|
|
|
{%- if case.status == 'SC' %}—{% else %}{{ case.long_status }}{% endif -%}
|
2020-01-21 06:35:58 +00:00
|
|
|
</span>
|
|
|
|
</td>
|
|
|
|
|
2021-05-26 17:10:19 +00:00
|
|
|
<td><span class="col-title">{{_('Point')}}: </span>
|
2022-11-20 03:41:43 +00:00
|
|
|
{{ case.points|floatformat }}/{{ case.total|floatformat }}
|
2021-05-26 17:10:19 +00:00
|
|
|
</td>
|
2020-01-21 06:35:58 +00:00
|
|
|
<td>
|
|
|
|
{%- if case.status != 'SC' -%}
|
|
|
|
{%- if case.status == 'TLE' -%}
|
2020-03-17 06:11:03 +00:00
|
|
|
<span><span class="col-title">{{_('Time')}}: ></span>{{ (time_limit * 1000)|floatformat(0) }} ms</span>
|
2020-01-21 06:35:58 +00:00
|
|
|
{%- else -%}
|
2020-03-17 06:11:03 +00:00
|
|
|
<span title="{{ case.time }}s"><span class="col-title">{{_('Time')}}: </span>{{ (case.time * 1000)|floatformat(0) }} ms</span>
|
2020-01-21 06:35:58 +00:00
|
|
|
{%- endif -%}
|
|
|
|
{%- endif -%}
|
|
|
|
</td>
|
|
|
|
|
2020-03-17 06:11:03 +00:00
|
|
|
<td>{% if case.status != 'SC' %}<span class="col-title">{{_('Memory')}}: </span> {{ case.memory|kbdetailformat }}{% endif %}</td>
|
2020-01-21 06:35:58 +00:00
|
|
|
</tr>
|
|
|
|
|
2021-06-17 06:49:09 +00:00
|
|
|
{% if can_see_testcases %}
|
2021-05-26 17:10:19 +00:00
|
|
|
<tr id="{{ case.id }}-output" style="display:none" class="case-feedback toggled">
|
|
|
|
<td colspan="5">
|
|
|
|
<div class="case-info">
|
|
|
|
{% set curr_data = cases_data[case.case] %}
|
|
|
|
{% if curr_data != null %}
|
|
|
|
<strong>{{ _('Input:') }}</strong>
|
|
|
|
<pre class="case-output">{{ curr_data['input']|linebreaksbr }}</pre>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
<strong>{{ _('Output:') }}</strong>
|
|
|
|
<pre class="case-output">{{ case.output|linebreaksbr }}</pre>
|
2020-03-17 06:11:03 +00:00
|
|
|
|
2021-05-26 17:10:19 +00:00
|
|
|
{% if curr_data != null %}
|
|
|
|
<strong>{{ _('Answer:') }}</strong>
|
|
|
|
<pre class="case-output">{{ curr_data['answer']|linebreaksbr }}</pre>
|
2020-03-17 06:11:03 +00:00
|
|
|
{% endif %}
|
2021-05-26 17:10:19 +00:00
|
|
|
|
|
|
|
{% if case.extended_feedback or case.feedback %}
|
|
|
|
<strong>{{ _('Judge feedback:') }}</strong>
|
|
|
|
{% if case.feedback %}
|
|
|
|
<pre class="case-output">{{ case.feedback|linebreaksbr }}</pre>
|
|
|
|
{% endif %}
|
|
|
|
{% if case.extended_feedback %}
|
|
|
|
<pre class="case-output">{{ case.extended_feedback|linebreaksbr }}</pre>
|
|
|
|
{% endif %}
|
2020-03-17 06:11:03 +00:00
|
|
|
{% endif %}
|
2021-05-26 17:10:19 +00:00
|
|
|
</div>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
{% endif %}
|
|
|
|
{% endfor %}
|
2020-01-21 06:35:58 +00:00
|
|
|
{% endfor %}
|
2021-05-26 17:10:19 +00:00
|
|
|
</tbody></table>
|
2020-01-21 06:35:58 +00:00
|
|
|
|
|
|
|
{% if submission.is_graded %}
|
|
|
|
<br>
|
|
|
|
{% if submission.result != "AB" %}
|
|
|
|
{% if is_pretest and submission.result == "AC" %}
|
|
|
|
<br>
|
|
|
|
<i>{{ _('Passing pretests does not guarantee a full score on system tests.') }}</i>
|
|
|
|
{% endif %}
|
|
|
|
{% else %}
|
|
|
|
<b>{{ _('Submission aborted!') }}</b>
|
|
|
|
{% endif %}
|
|
|
|
<br>
|
|
|
|
{% endif %}
|
|
|
|
{% endif %}
|
|
|
|
{% else %}
|
|
|
|
{% include "submission/internal-error-message.html" %}
|
|
|
|
{% endif %}
|