查看: 1515|回復: 2
打印 上一主題 下一主題

[範本]TOJ投稿題目範本 Hello World!

[複製鏈接]
  • TA的每日心情
    慵懶
    2015-4-10 14:18
  • 簽到天數: 78 天

    [LV.6]常住居民II

    176

    主題

    612

    帖子

    3959

    積分

    管理員

    Rank: 9Rank: 9Rank: 9

    積分
    3959

    台南一中資訊社新手達陣程式設計達人 - 2014

    跳轉到指定樓層
    樓主
    發表於 2014-4-27 11:21:46 | 顯示全部樓層 回帖獎勵 |倒序瀏覽 |閱讀模式

    趕快加入我們來參與討論吧!

    您需要 登錄 才可以下載或查看,沒有帳號?加入我們

    x
    本文示範TOJ的投稿格式。
    參考資料:By PZread
    @The Structure Of Problems

  • the structure of the .tar.xz file
  • conf.json
  • http/cont.html or http/cont.pdf
  • res/testdata/[number].in
  • res/testdata/[number].out

  • If use Makefile
  • res/make/Makefile
  • res/make/[other files needed in make]

  • Note:
  • If cont.html exists, cont.pdf will be ignored.
  • Pack all data into one .tar.xz file, and don’t create any top level directory, just pack conf.json, res, http into .tar.xz directly.
  • CRLFs in testdata will be automatically converted to *nix format.
  • Challenger need to pass all testdata to get the testcase point.
  • The author of this document is bad at English.
  • tar -Jcvf dest_file_name.tar.xz conf.json res http


  • Some conf.json sample


  • clang++ with signle testcase
  • {
  •         "timelimit":4000,
  •         "memlimit":32768,
  •         "compile":"g++",
  •         "score":"rate",
  •         "check":"diff",
  •         "test":[
  •                 {
  •                         "data":[1],
  •                         "weight":100
  •                 }
  •         ]
  • }


  • clang++ with two testcase, first testcase has three testdata (1.in 2.in 3.in)
  • {
  •         "timelimit":1000,
  •         "memlimit":65536,
  •         "compile":"g++",
  •         "score":"rate",
  •         "check":"diff",
  •         "test":[
  •                 {
  •                          "data":[1,2,3],
  •                         "weight":50
  •                 },
  •                 {
  •                          "data":[4,5],
  •                         "weight":50
  •                 }
  •         ]
  • }

  • 難疑排解 FAQ
    Q1. .tar.xz格式如何製作?
    A.用7-zip把檔案先封成.tar格式後再壓縮成.xz格式

    [範本]
    投稿題目:Hello World!
    題目來源:原創題
    題幹:基本IO

    題目敘述:
    (完整敘述須放置於檔案之/html目錄下,僅接受cont.html及cont.pdf兩種,cont.html優先使用)

    跟別人打招呼是一件有禮貌的事。來向大家打招呼吧!



    輸入說明:
    向他打個招呼吧!名子加上 Hello ,[name] ! 後輸出。

    範例輸入:
    (請用code標籤)
    @Peter


    範例輸出:
    (請用code標籤)
    @Hello ,Peter !

    標程:
    @#include<cstdio>
  • #include<iostream>

  • using namespace std;

  • int main()
  • {
  •         char in[25];
  •         gets(in);
  •         printf("Hello ,%s !\n",in);
  •         return 0;
  • }

  • 測試資料下載:
    (請符合正確的檔案格式)
    mega網頁範本:
    http://pc2.twbbs.org:81/lfs/cont.html

    欲投稿題目者,只需提供題目敘述、測資、標準程式,並發文至題目發表頁面。
    回復

    使用道具 檢舉

    您需要登錄後才可以回帖 登入 | 加入我們

    本版積分規則

    快速回覆 返回頂部 返回列表