MAIN Home When Schedule Registration Rules About Language Prizes RESULTS Standings LINKS LSU Computer Science Contest Index HS 2002 HS 2001 HS 2000 ACM Intl PC PC2 Printable
| |
This page includes instructions and information about all the languages we intend to supply/support/use at the
LSU Computer Science High School Programming Contest.
Table of Contents:
Return to Top of Page
Borland Turbo Pascal v1.5 for Windows
NOTES | To Make It Work | Example Program | Judging Information
NOTES:
- You must not try to use the debugger!!! It does not work and will crash the system (Turbo Pascal at least)!
- You must have the uses WinCRT; at the top of your program to get output.
- You should only use READ, READLN, WRITE, and WRITELN for I/O.
To Make It Work:
Example Program:
program Welcome;
uses WinCRT;
var
name: string;
begin
Assign(Input,'input.txt'); Reset(Input);
Assign(Output,'output.txt'); Rewrite(Output);
Readln(name);
Writeln('Welcome to Turbo Pascal for Windows, ',name);
Close(Output);
end.
Items in red are the needed additions for file I/O using standard I/O commands.
Judging Information:
- Look at the source for:
- Make sure there is a uses WinCRT; section
- Make sure the following two lines are just after the begin of the main program (if they aren't already there):
Assign(Input,'C:\TEMP\test.in'); Reset(Input);
Assign(Output,'C:\TEMP\test.out'); Rewrite(Output);
- Make sure the following line is just before the end. of the main program:
If any of these sections aren't there, return IS - Improper Submission
Return to Top of Page
Borland Delphi v6.0
NOTES | To Make It Work | Example Program | Judging Information
Return to Top of Page
Microsoft QBasic
NOTES | To Make It Work | Example Program | Judging Information
Example Program:
rem Practice Problem
input name$
print "Hello ", name$
Judging Information:
- You will need to exit the QBasic window (Under File, select Exit)
- The output file will have a ? followed by input for every line of input the program processes.
Return to Top of Page
Microsoft Visual Basic v6.0
NOTES | Example Program | Judging Information
NOTES:
- When you create your project, just select the standard.exe, not a GUI.
Do not use any forms in your application!
Instead, create a Module that has at least one subroutine called Main.
Submit only your Module file (.bas file) filename.bas (we just need the Module source-- not the whole project).
- You must name your main subroutine Main!
To Make It Work:
Command Line Compiles:To compile a Visual Basic Program, type on the command line
where MYPROG.vbp is your project file.( You should have at least two files: a .vbp file and a .bas file. This will produce a file called MYPROG.exe.
Example Program:
Private Sub Main()
Close #1
Open "input.txt" For Input As #1
Open "output.txt" For Append As #2
Dim name as string
Input #1, name
Print #2, "Hello ",name
Close #1
Close #2
End Sub
Judging Information:
- If the red section isn't there, return IS - Improper Submission
- Here is a sample Project.vbp file. This is the file that is given to the program VB6.exe for compiling.
This particular project has only one source file referenced in it, a module called module.bas.
Return to Top of Page
Microsoft Visual C/C++ v6.0
NOTES | To Make It Work | Example Program
Return to Top of Page
SUN Java 2 SDK Standard Edition 1.4.0
NOTES | To Make It Work | Example Program | Judging Information
Judging Information:
Return to Top of Page
|