User Tools

Site Tools


running_pc2

Student Notes for Competing Using PC^2

  1. One time only: copy /homes/cs390cp/pc2/pc2v9.ini to your local directory somewhere (e.g., ~/pc2).
  2. Change into the directory where your pc2v9.ini file is located.
  3. Launch pc2: /homes/cs390cp/pc2/bin/pc2team &
  4. Log in as teamX/teamX, where X is assigned to you by administrator.

Administrator Notes for Running Programming Competitions with PC^2

Account Setup

  1. Login to cs390cp@pc.cs.purdue.edu
  2. cd pc2 (assumes pc2 is a symlink to current version, pc2-9.3.1; pc2v9.ini edited to point to server at pc.cs.purdue.edu)
  3. pc2reset [if necessary/desired]
  4. pc2server & (assumes pc2/bin is in path)
  5. Login as site1; choose contest password
  6. pc2admin &
  7. Login as administrator1
  8. Languages tab, Add, Auto Populate with Java and GNU C++, possibly GNU C
  9. Accounts tab, Generate accounts (1 judge, x teams, 1 scoreboard)
    1. Load account information from file (see http://pc2.ecs.csus.edu/wiki/Load_Account)
    2. File generated by web2py in progress/private with dotask genpc2accounts.py

Before Weekly Class

  1. Create snapshot of current pc2 setup
    1. Exit pc2 (server and admin)
    2. cd ~
    3. cp -pr pc2-9.2.3 pc2-contest
  2. cd pc2-contest
  3. rm archive/*
  4. Launch server and admin, login
  5. Problems tab, Add (repeat for each problem)
    1. Problem name
    2. Problem Requires Input Data, Stdin, Input Data File
    3. Judges have Provided Answer File
    4. Judging Type tab: Computer judging
    5. Validator tab: Use PC^2 validator with option “1 - diff”
  6. Auto judge tab
    1. Select judge1, Edit
    2. Shift-select all problems, Enable Auto Judging, Update

In Class

  1. cd to pc2-contest directory
  2. Relaunch: pc2server and pc2admin
  3. Times tab (pc2admin)
    1. Select site1, Edit
    2. Set/update remaining, elapsed, and length times
    3. Start ALL
  4. bin/pc2judge &
    1. Login as judge1/judge1
  5. bin/pc2board &
    1. Login as scoreboard1/scoreboard1
  6. firefox html/summary.html

After Competition

  1. pc2reset
  2. Copy archive into main directory (~/pc2-9.2.3)
  3. Remove pc2-contest
running_pc2.txt · Last modified: 2012/10/23 16:17 by jtkorb